mkdistsellallocation.html 9.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <title>渠道销售分配,分销商针对某个商品sku的销售分配</title>
  5. #parse("sys/header.html")
  6. </head>
  7. <body>
  8. <div id="rrapp" v-cloak>
  9. <div v-show="showList">
  10. <Row :gutter="16">
  11. <div class="search-group">
  12. <i-col span="3">
  13. <i-select v-model="q.distChnlId" placeholder="分销渠道" @on-change="queryChangeByDistChnlId">
  14. <i-option v-for="chnl in queryMkDistChnlList" :value="chnl.distChnlId" :key="chnl.distChnlId">{{chnl.distFlag}}
  15. </i-option>
  16. </i-select>
  17. </i-col>
  18. <i-col span="3">
  19. <i-select v-model="q.distId" placeholder="分销商" >
  20. <i-option v-for="dist in queryMkDistList" :value="dist.distId" :key="dist.distId">{{dist.distName}}
  21. </i-option>
  22. </i-select>
  23. </i-col>
  24. <i-col span="3">
  25. <i-select v-model="q.storeId" placeholder="门店" @on-change="queryChangeGoodsByStore">
  26. <i-option v-for="store in queryStoreList" :value="store.id" :key="store.id">{{store.storeName}}
  27. </i-option>
  28. </i-select>
  29. </i-col>
  30. <i-col span="3">
  31. <i-select v-model="q.goodsId" placeholder="商品" >
  32. <i-option v-for="goods in queryGoodsList" :value="goods.goodsId" :key="goods.goodsId">{{goods.goodsName}}
  33. </i-option>
  34. </i-select>
  35. </i-col>
  36. <i-button @click="query">查询</i-button>
  37. <i-button @click="reloadSearch">重置</i-button>
  38. </div>
  39. <div class="buttons-group">
  40. #if($shiro.hasPermission("mkdistsellallocation:save"))
  41. <i-button type="info" @click="add"><i class="fa fa-plus"></i>&nbsp;新增</i-button>
  42. #end
  43. #if($shiro.hasPermission("mkdistsellallocation:update"))
  44. <i-button type="warning" @click="update"><i class="fa fa-pencil-square-o"></i>&nbsp;修改</i-button>
  45. #end
  46. #if($shiro.hasPermission("mkdistsellallocation:delete"))
  47. <i-button type="error" @click="del"><i class="fa fa-trash-o"></i>&nbsp;删除</i-button>
  48. #end
  49. </div>
  50. </Row>
  51. <table id="jqGrid"></table>
  52. <div id="jqGridPager"></div>
  53. </div>
  54. <Card v-show="!showList">
  55. <p slot="title">{{title}}</p>
  56. <i-form ref="formValidate" :model="mkDistSellAllocation" :rules="ruleValidate" :label-width="120">
  57. <!--<Form-item label="分销渠道id" prop="distChnlId">-->
  58. <!--&lt;!&ndash;<i-input v-model="mkDistSellAllocation.distFlag" placeholder="分销渠道名称"/>&ndash;&gt;-->
  59. <!--<i-select v-model="mkDistSellAllocation.distChnlId" placeholder="分销渠道名称" style="width: 268px;" @on-change="changeDist" label-in-value>-->
  60. <!--<i-option v-for="mkDistChnl in mkDistChnlList" :value="mkDistChnl.distChnlId" :key="mkDistChnl.distChnlId">{{mkDistChnl.distFlag}}-->
  61. <!--</i-option>-->
  62. <!--</i-select>-->
  63. <!--</Form-item>-->
  64. <Form-item label="所属三方商户" prop="thirdMerchSn">
  65. <!--<i-input v-model="mkDistSellAllocation.thirdMerchSn" placeholder="所属三方商户"/>-->
  66. <i-select v-model="mkDistSellAllocation.thirdMerchSn" placeholder="所属三方商户" style="width: 268px;" @on-change="changeDist" label-in-value>
  67. <i-option v-for="thirdMerchant in thirdMerchantBizList" :value="thirdMerchant.thirdMerchSn" :key="thirdMerchant.thirdMerchSn">{{thirdMerchant.thirdPartyMerchName}}</i-option>
  68. </i-select>
  69. </Form-item>
  70. <Form-item label="所属供应商" prop="supplierId">
  71. <!--<i-input v-model="mkDistSellAllocation.supplierId" placeholder="所属供应商"/>-->
  72. <i-select v-model="mkDistSellAllocation.supplierId" placeholder="所属供应商" style="width: 268px;" label-in-value>
  73. <i-option v-for="supplier in suppliers" :value="supplier.id" :key="supplier.id">{{supplier.childSupplierName}}
  74. </i-option>
  75. </i-select>
  76. </Form-item>
  77. <Form-item label="所属门店" prop="storeId">
  78. <i-select v-model="mkDistSellAllocation.storeId" placeholder="所属门店" style="width: 268px;" label-in-value @on-change="changeGoods">
  79. <i-option v-for="store in storeList" :value="store.id" :key="store.id">{{store.storeName}}
  80. </i-option>
  81. </i-select>
  82. </Form-item>
  83. <Form-item label="商品所属分销商" prop="distId">
  84. <i-select v-model="mkDistSellAllocation.distId" placeholder="分销商" style="width: 268px;" label-in-value>
  85. <i-option v-for="mkDist in mkDistList" :value="mkDist.distId" :key="mkDist.distId">{{mkDist.distName}}
  86. </i-option>
  87. </i-select>
  88. </Form-item>
  89. <Form-item label="商品id" prop="goodsId">
  90. <i-select v-model="mkDistSellAllocation.goodsId" placeholder="商品id" style="width: 268px;" @on-change="showTree" label-in-value>
  91. <i-option v-for="goods in goodsList" :value="goods.goodsId" :key="goods.goodsId">{{goods.goodsName}}
  92. </i-option>
  93. </i-select>
  94. </Form-item>
  95. <Form-item label="分配方式" prop="allocType">
  96. <i-select v-model="mkDistSellAllocation.allocType" placeholder="分配方式" style="width: 268px;" label-in-value>
  97. <i-option value="00" :key="mkDistSellAllocation.id">比例
  98. </i-option>
  99. <i-option value="10" :key="mkDistSellAllocation.id">金额
  100. </i-option>
  101. </i-select>
  102. </Form-item>
  103. <Form-item label="分销额度分配" prop="allocType">
  104. <div v-for="(item,index) in expendDistList" >
  105. <div class="row">
  106. <div class="col-md-3">
  107. <label class="ivu-form-item-label">{{item.expendDistLvl != '' ? item.expendDistLvl+'级':'上级'}}分销商:</label>
  108. <div class="col-md-4 input-icon right">
  109. <!--<i-input type="text" v-model="item.expendDistName"/>-->
  110. <i-select v-model="item.expendDistId" placeholder="分销商" style="width: 268px;" label-in-value>
  111. <i-option :value="item.expendDistId" :key="item.expendDistId">{{item.expendDistName}}
  112. </i-option>
  113. </i-select>
  114. </div>
  115. </div>
  116. <div class="col-md-4">
  117. <label class="ivu-form-item-label">{{item.expendDistLvl != '' ? item.expendDistLvl+'级':'上级'}}分销商分配额度(比例/金额):</label>
  118. <div class="col-md-5 input-icon right">
  119. <i-input type="text" v-model="item.expendDistLine"/>
  120. </div>
  121. </div>
  122. </div>
  123. </div>
  124. <div><span style="color: red">{{expendDistList.length == 0 ? '请先维护选择的商品所属分销商的层级关系':''}}</span></div>
  125. </Form-item>
  126. <!--<Form-item label="支出分销商id">-->
  127. <!--&lt;!&ndash;<i-input v-model="mkDistSellAllocation.expendDistIds" placeholder="支出分销商id"/>&ndash;&gt;-->
  128. <!--<div style="overflow-y: auto; max-height: 250px;width: 300px; border: 1px solid #cccccc;">-->
  129. <!--<ul id="expendDistIdsTree" class="ztree"></ul>-->
  130. <!--</div>-->
  131. <!--</Form-item>-->
  132. <!--<Row>-->
  133. <!--<i-col span="16" style="margin-top: -10px;">-->
  134. <!--<span style="margin-left: 120px; color: red; font-size: 12px;">* 额度需与支出分销商对应排序,由,拼接,逗号为英文小写。示例:比例1,比例2,比例3...</span>-->
  135. <!--</i-col>-->
  136. <!--</Row>-->
  137. <!--<Form-item label="支出分销商对应额度(比例/金额)" prop="expendDistLines">-->
  138. <!--<i-input v-model="mkDistSellAllocation.expendDistLines" placeholder="支出分销商对应额度(比例/金额)"/>-->
  139. <!--</Form-item>-->
  140. <Form-item label="是否有效" prop="isValid" label-in-value style="margin-top: 20px;">
  141. <Radio-group v-model="mkDistSellAllocation.isValid">
  142. <Radio label="1">
  143. <span>无效</span>
  144. </Radio>
  145. <Radio label="0">
  146. <span>有效</span>
  147. </Radio>
  148. </Radio-group>
  149. </Form-item>
  150. <Form-item label="备注" prop="note">
  151. <i-input v-model="mkDistSellAllocation.note" placeholder="备注"/>
  152. </Form-item>
  153. <Form-item>
  154. <i-button type="primary" @click="handleSubmit('formValidate')">提交</i-button>
  155. <i-button type="warning" @click="reload" style="margin-left: 8px"/>返回</i-button>
  156. <i-button type="ghost" @click="handleReset('formValidate')" style="margin-left: 8px">重置</i-button>
  157. </Form-item>
  158. </i-form>
  159. </Card>
  160. </div>
  161. <script src="${rc.contextPath}/js/mk/mkdistsellallocation.js?_${date.systemTime}"></script>
  162. </body>
  163. </html>