Du kan inte välja fler än 25 ämnen Ämnen måste starta med en bokstav eller siffra, kan innehålla bindestreck ('-') och vara max 35 tecken långa.

newFollowup.vue 7.3 KiB

2 år sedan
2 år sedan
2 år sedan
2 år sedan
2 år sedan
2 år sedan
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330
  1. <template>
  2. <view class="box">
  3. <view class="screen">
  4. <!-- 录音标示 -->
  5. <view class="screen-record">
  6. <view class="screen-record-text">
  7. 客户阶段
  8. </view>
  9. <view class="screen-record-tab">
  10. <scroll-view scroll-x style="width: 100%;">
  11. <view style="display: flex;">
  12. <block v-for="(item,index) in stateList" :key="index">
  13. <view style="flex-shrink: 0;"
  14. :class="[screen.state==index?'screen-record-chose':'screen-record-nochose']"
  15. @click="screen.state=index">
  16. {{item.stageName}}
  17. </view>
  18. </block>
  19. </view>
  20. </scroll-view>
  21. </view>
  22. </view>
  23. <!-- 录音标示 -->
  24. <view class="screen-record">
  25. <view class="screen-record-text">
  26. 意向级别
  27. </view>
  28. <view class="screen-record-tab">
  29. <view :class="[screen.level==1?'screen-record-chose':'screen-record-nochose']"
  30. @click="screen.level=1">
  31. A
  32. </view>
  33. <view :class="[screen.level==2?'screen-record-chose':'screen-record-nochose']"
  34. @click="screen.level=2">
  35. B
  36. </view>
  37. <view :class="[screen.level==3?'screen-record-chose':'screen-record-nochose']"
  38. @click="screen.level=3">
  39. C
  40. </view>
  41. <view :class="[screen.level==4?'screen-record-chose':'screen-record-nochose']"
  42. @click="screen.level=4">
  43. D
  44. </view>
  45. </view>
  46. </view>
  47. <!-- <view class="screen-record" style="height: auto;">
  48. <view class="screen-record-text" style="margin-bottom: 20rpx;">
  49. 客户类型
  50. </view>
  51. <u-search placeholder="请输入搜索" v-model="keyword" :clearabled="true" :show-action="false" @change="search"></u-search>
  52. <scroll-view style="height: 180rpx;" scroll-y="true" >
  53. <view class="screen-record-tab" style="flex-wrap: wrap;">
  54. <view v-for="(item,index) in customerType" :key="index">
  55. <view :class="[item.check?'screen-record-chose':'screen-record-nochose']" style="margin-bottom: 20rpx;" @click="checkbox(index)">
  56. {{item.keywords}}
  57. </view>
  58. </view>
  59. </view>
  60. </scroll-view>
  61. </view> -->
  62. <view class="screen-record">
  63. <view class="screen-record-text">
  64. 跟进内容
  65. </view>
  66. <view class="screen-record-tab">
  67. <input type="text" placeholder="请输入跟进内容" v-model="screen.con" />
  68. </view>
  69. </view>
  70. <view class="screen-foot">
  71. <view class="screen-foot-sure" @click="screensure">
  72. 保存
  73. </view>
  74. </view>
  75. </view>
  76. </view>
  77. </template>
  78. <script>
  79. export default {
  80. data() {
  81. return {
  82. value: '',
  83. screenShow: false,
  84. selectshow: false,
  85. selectTipshow: false,
  86. buildingID: '',
  87. keyword: '',
  88. screen: {
  89. state: '0',
  90. con: "",
  91. level: '1'
  92. },
  93. stateList: [],
  94. recordList: [],
  95. nextPage: 1,
  96. totalRecord: '',
  97. freeList: [],
  98. customerType: [],
  99. customerId: ''
  100. }
  101. },
  102. onShow() {
  103. },
  104. onLoad(e) {
  105. this.customerId = e.id
  106. this.buildingID = uni.getStorageSync('buildingID').id;
  107. this.recordList = []
  108. if (e.level) {
  109. this.screen.level = Number(e.level)
  110. }
  111. // this.getMyCustom()
  112. // this.getFreeList()
  113. this.getNewStatus(e)
  114. this.getCustomerType();
  115. },
  116. methods: {
  117. //选择顾问
  118. actionSelectCallback(e) {
  119. this.screen.agentId = e[0].value;
  120. this.screen.agentIdtext = e[0].label;
  121. },
  122. getCustomerType() {
  123. this.$u.get("/customer/queryKeyWords").then(res => {
  124. res.map(item => {
  125. item.check = false
  126. })
  127. this.customerType = res;
  128. })
  129. },
  130. getNewStatus(e) {
  131. var that = this;
  132. let premo = {
  133. houseId: uni.getStorageSync('buildingID').id
  134. }
  135. this.$u.post('/customer/getStage', premo)
  136. .then(res => {
  137. console.log(res)
  138. console.log(e.stageName, res.findIndex(item => item.stageName == e.stageName ))
  139. if (e.stageName) {
  140. that.screen.state = res.findIndex(item => item.stageName == e.stageName )
  141. }
  142. that.stateList = res
  143. })
  144. },
  145. checkbox(idx) {
  146. console.log(idx)
  147. this.customerType[idx].check = !this.customerType[idx].check
  148. },
  149. search(e) {
  150. console.log(e)
  151. },
  152. //选择标签
  153. selectCallback(e) {
  154. console.log(e[0].label)
  155. },
  156. //筛选确认
  157. screensure() {
  158. // 获取选择过的数据
  159. // let type=[]
  160. let words = []
  161. this.customerType.map(item => {
  162. if (item.check) {
  163. // type.push(item.id)
  164. words.push(item.keywords)
  165. }
  166. })
  167. // if (words.length == 0 ) {
  168. // uni.showModal({
  169. // title: '提示',
  170. // content: '请选择、类型',
  171. // showCancel: false
  172. // });
  173. // return;
  174. // }
  175. uni.showLoading({
  176. title: "保存中~",
  177. mask: true
  178. })
  179. // console.log(type)
  180. let param = {
  181. "stageCode": this.stateList[this.screen.state].stageCode,
  182. "stageName": this.stateList[this.screen.state].stageName,
  183. "remarks": this.screen.con,
  184. words,
  185. // "settingTime":"",
  186. "agentRelationPo": {
  187. "customerId": this.customerId,
  188. "level": this.screen.level,
  189. "state": this.stateList[this.screen.state].id
  190. }
  191. }
  192. this.$u.post('/customer/addZkDailyWorkRecord', param)
  193. .then(res => {
  194. // util.showSuccess("提交成功");
  195. uni.hideLoading();
  196. uni.navigateBack();
  197. })
  198. },
  199. }
  200. }
  201. </script>
  202. <style lang="scss" scoped>
  203. .box {
  204. width: 100%;
  205. height: 100%;
  206. background: #F8F8F8;
  207. }
  208. .screen {
  209. // box-sizing: border-box;
  210. // padding: 0 30rpx;
  211. background: #FFFFFF;
  212. .screen-counselor {
  213. display: flex;
  214. height: 106rpx;
  215. // padding: 40rpx 30rpx 36rpx 30rpx;
  216. padding: 0 30rpx;
  217. box-sizing: border-box;
  218. border-bottom: 1px solid #CCCCCC;
  219. .screen-text {
  220. margin: 40rpx 0 36rpx 0;
  221. font-size: 30rpx;
  222. font-weight: 400;
  223. color: #333333;
  224. line-height: 30rpx;
  225. }
  226. .screen-sel {
  227. display: flex;
  228. justify-content: space-between;
  229. width: 500rpx;
  230. margin-left: 60rpx;
  231. .screen-sel-img {
  232. margin: 40rpx 0 36rpx 0;
  233. width: 14rpx;
  234. height: 30rpx;
  235. }
  236. .screen-inp {
  237. margin-top: 20rpx;
  238. }
  239. }
  240. }
  241. .screen-record {
  242. height: 192rpx;
  243. // width: 100%;
  244. overflow: hidden;
  245. padding: 0 30rpx;
  246. box-sizing: border-box;
  247. border-bottom: 1px solid #CCCCCC;
  248. .screen-record-text {
  249. margin-top: 36rpx;
  250. font-size: 30rpx;
  251. font-weight: 400;
  252. color: #333333;
  253. line-height: 30rpx;
  254. }
  255. .screen-record-tab {
  256. margin-top: 30rpx;
  257. display: flex;
  258. // justify-content: space-around;
  259. .screen-record-chose {
  260. width: 151rpx;
  261. height: 60rpx;
  262. background: #FFFFFF;
  263. border-radius: 4rpx;
  264. border: 1px solid #2671E2;
  265. text-align: center;
  266. line-height: 60rpx;
  267. margin-right: 22rpx;
  268. }
  269. .screen-record-nochose {
  270. width: 151rpx;
  271. height: 60rpx;
  272. background: #FFFFFF;
  273. border-radius: 4rpx;
  274. border: 1px solid #C9C9C9;
  275. text-align: center;
  276. line-height: 60rpx;
  277. margin-right: 22rpx;
  278. }
  279. }
  280. }
  281. .screen-foot {
  282. height: 88rpx;
  283. display: flex;
  284. width: 100%;
  285. margin-top: 160rpx;
  286. .screen-foot-reset {
  287. width: 80%;
  288. text-align: center;
  289. margin: 0 auto;
  290. line-height: 88rpx;
  291. font-size: 30rpx;
  292. font-weight: 400;
  293. color: #666666;
  294. }
  295. .screen-foot-sure {
  296. width: 80%;
  297. margin: 0 auto;
  298. text-align: center;
  299. line-height: 88rpx;
  300. font-size: 30rpx;
  301. font-weight: 400;
  302. color: #FFFFFF;
  303. background: #2671E2;
  304. }
  305. }
  306. }
  307. </style>