b64856ac84cb17447558a4c323714b34631c9c65.svn-base 66 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544
  1. <template>
  2. <div class="app-container">
  3. <div class="menuList">
  4. <div class="menuList-t">
  5. <div class="menuList-t-l">
  6. <span>班次:</span>
  7. <el-radio-group v-model="menuRadio" size="small" @change="changeMenu">
  8. <el-radio-button v-if="maxTime.isTime1" label="一班">一班</el-radio-button>
  9. <el-radio-button v-if="maxTime.isTime2" label="二班">二班</el-radio-button>
  10. <el-radio-button v-if="maxTime.isTime3" label="三班">三班</el-radio-button>
  11. <el-radio-button v-if="maxTime.isTime4" label="四班">四班</el-radio-button>
  12. </el-radio-group>
  13. </div>
  14. <div class="menuList-t-r">
  15. <div v-if="!isBarracks" class="menuList-t-r-l" @click="clickBarracks(2);">栏舍计划统计-展开<i class="el-icon-arrow-down" /></div>
  16. <div v-if="isBarracks" class="menuList-t-r-r" @click="clickBarracks(1);">栏舍计划统计-收起<i class="el-icon-arrow-up" /></div>
  17. <div v-if="isBarracks" class="columnHouse">
  18. <div class="smallTable">
  19. <el-table
  20. :list-loading="smallMenu.listLoading"
  21. element-loading-text="给我一点时间"
  22. :data="smallMenu.list"
  23. :row-style="rowStyle2"
  24. :cell-style="cellStyle2"
  25. :header-row-style="headerRowStyle2"
  26. :header-cell-style="headerCellStyle2"
  27. show-summary
  28. sum-text="总栏舍"
  29. class="elTable"
  30. >
  31. <el-table-column label="配方/班次" min-width="80px" align="center" prop="tname" />
  32. <el-table-column label="总数" min-width="50px" align="center" prop="usedsum" />
  33. <el-table-column v-if="maxTime.isTime1" label="第一班未分配" min-width="105px" align="center" prop="onetime" />
  34. <el-table-column v-if="maxTime.isTime2" label="第二班未分配" min-width="105px" align="center" prop="twotime" />
  35. <el-table-column v-if="maxTime.isTime3" label="第三班未分配" min-width="105px" align="center" prop="threetime" />
  36. <el-table-column v-if="maxTime.isTime4" label="第四班未分配" min-width="105px" align="center" prop="fourtime" />
  37. </el-table>
  38. </div>
  39. </div>
  40. </div>
  41. </div>
  42. <div class="menuList-b">
  43. <ul v-loading="listLoadingTimes" class="draggableList">
  44. <li v-for="element in MenuList" :key="element.arrid">
  45. <span v-if="element.isShowTitle" class="draggableTitle">{{ element.ftname }}:</span>
  46. <draggable id="1" data-source="juju1" :list="element.arrList" class="list-group1" draggable=".item" group="a" :move="move" @change="changeLog" @start="start" @end="end">
  47. <div v-for="item in element.arrList" :key="item.id" class="list-group-item1 item" style="width: 88px;float: left;margin:5px 5px;height: 36px;">
  48. <el-tooltip placement="top" class="list-group-item1 item" style="height: 18px;line-height: 18px;" :style="{'background':item.background}">
  49. <div slot="content">{{ item.barname }}</div>
  50. <div class="draggableName not-select">{{ item.barname }}</div>
  51. </el-tooltip>
  52. <div class="draggableWeight not-select" :style="{ background: 'rgba('+item.background2+ ',0.1)' }"> {{ item.weight }} </div>
  53. </div>
  54. </draggable>
  55. </li>
  56. </ul>
  57. </div>
  58. </div>
  59. <div ref="list" class="list">
  60. <div class="operation">
  61. <el-button class="success" icon="el-icon-plus" style="float:left;" @click="handleCreate">新增车次</el-button>
  62. <el-button class="danger" icon="el-icon-delete" style="float:left;" @click="handleReduceTrains">减少车次</el-button>
  63. <el-button class="success" icon="el-icon-download" style="float:left;" @click="handleAutomaticGeneration">自动生成</el-button>
  64. <el-button v-if="isOrder" icon="el-icon-sort" style="float: left;" class="success" @click="handleChangeOrder">更改顺序</el-button>
  65. <div v-else style="float: left;margin-left: 10px;">
  66. <el-button icon="el-icon-folder-checked" class="success" @click="saveChangeOrder">保存</el-button>
  67. <el-button icon="el-icon-close" class="sortCancel" @click="cancelChangeOrder">取消</el-button>
  68. </div>
  69. <el-button class="success" icon="el-icon-time" style="float:right;" @click="handleHistoryRecord">历史记录</el-button>
  70. </div>
  71. <div class="table">
  72. <el-table
  73. id="table"
  74. :key="table.tableKey"
  75. ref="table"
  76. v-loading="table.listLoading"
  77. element-loading-text="给我一点时间"
  78. :data="table.list"
  79. border
  80. highlight-current-row
  81. style="width: 100%;"
  82. :height="height"
  83. :row-style="rowStyle"
  84. :cell-style="cellStyle"
  85. class="elTable"
  86. row-key="id"
  87. @selection-change="handleSelect"
  88. >
  89. <el-table-column type="selection" width="50" />
  90. <el-table-column label="车次" width="85px" align="center">
  91. <template slot-scope="scope">
  92. <span v-if="scope.row.NoEdit">{{ scope.row.sort }}</span>
  93. <el-input v-if="scope.row.Edit" v-model="scope.row.sort" type="number" placeholder="车次" class="filter-item" style="display: inline-block;width: 95%;" />
  94. </template>
  95. </el-table-column>
  96. <el-table-column label="TMR编号" width="110px" align="center">
  97. <template slot-scope="scope">
  98. <span v-if="scope.row.NoEdit">{{ scope.row.tmrname }}</span>
  99. <el-select v-if="scope.row.Edit" v-model="scope.row.tmrid" placeholder="TMR编号" class="filter-item" style="width:95%;" @change="(value)=> {changeTMRNumber(value, scope.row)}">
  100. <el-option v-for="item in TMRNumberList" :key="item.id" :label="item.eqcode" :value="item.id" />
  101. </el-select>
  102. </template>
  103. </el-table-column>
  104. <el-table-column label="描述" width="110px" align="center">
  105. <template slot-scope="scope">
  106. <span v-if="scope.row.NoEdit">{{ scope.row.display }}</span>
  107. <el-input v-if="scope.row.Edit" v-model="scope.row.display" type="textarea" :autosize="{ minRows: 1.3, maxRows: 4}" placeholder="描述" maxlength="255" class="filter-item" style="display: inline-block;width: 95%;" />
  108. </template>
  109. </el-table-column>
  110. <el-table-column label="生效" width="100px" align="center">
  111. <template slot-scope="scope">
  112. <el-switch v-model="scope.row.sel" :disabled="scope.row.NoEdit" active-color="#13ce66" inactive-color="#ff4949" :active-value="1" :inactive-value="0" @change="handleTakeEffectChange(scope.$index, scope.row)" />
  113. </template>
  114. </el-table-column>
  115. <el-table-column label="班次" width="100px" align="center">
  116. <template slot-scope="scope">
  117. <span v-if="scope.row.NoEdit">{{ scope.row.timesstr }}</span>
  118. <el-select v-if="scope.row.Edit" v-model="scope.row.times" :disabled="scope.row.Disabled" placeholder="班次" class="filter-item" style="width:95%;">
  119. <el-option v-for="item in frequencyList" :key="item.id" :label="item.name" :value="item.id" />
  120. </el-select>
  121. </template>
  122. </el-table-column>
  123. <el-table-column label="时间" width="150px" align="center">
  124. <template slot-scope="scope">
  125. <span v-if="scope.row.NoEdit">{{ scope.row.begintime }}</span>
  126. <el-time-picker v-if="scope.row.Edit" v-model="scope.row.begintime" type="datetime" placeholder="选择时间" format="HH:mm" value-format="HH:mm" style="display: inline-block;width: 95%;" />
  127. </template>
  128. </el-table-column>
  129. <el-table-column label="最大重量" width="80px" align="center">
  130. <template slot-scope="scope">
  131. <span>{{ scope.row.maxweight }}</span>
  132. </template>
  133. </el-table-column>
  134. <el-table-column label="合计重量" width="80px" align="center">
  135. <template slot-scope="scope">
  136. <span>{{ scope.row.sumweight }}</span>
  137. </template>
  138. </el-table-column>
  139. <el-table-column label="模板配方" width="120px" align="center">
  140. <template slot-scope="scope">
  141. <span v-if="scope.row.NoEdit">{{ scope.row.ftname }}</span>
  142. <el-select v-if="scope.row.Edit" v-model="scope.row.ftid" :disabled="scope.row.Disabled" placeholder="模板配方" class="filter-item" style="width:95%;" @change="(value)=> {changeTemplateFormulation(value, scope.row)}">
  143. <el-option v-for="item in templateFormulationList" :key="item.id" :label="item.tname" :value="item.id" />
  144. </el-select>
  145. </template>
  146. </el-table-column>
  147. <el-table-column label="是否提前小料拆分" width="100px" align="center">
  148. <template slot-scope="scope">
  149. <el-switch v-model="scope.row.issplit" :disabled="scope.row.NoEdit" active-color="#13ce66" inactive-color="#ff4949" :active-value="1" :inactive-value="0" @change="handleIssplitChange(scope.$index, scope.row)" />
  150. </template>
  151. </el-table-column>
  152. <el-table-column label="撒料" width="950px" align="center">
  153. <template slot-scope="scope">
  154. <draggable id="2" data-source="juju" :list="scope.row.arrList" class="list-group2" draggable=".item" group="a" :move="move2" @change="changeLog2(scope.row)" @start="start2" @end="end2(scope.row)">
  155. <div v-for="element in scope.row.arrList" :key="element.name" class="list-group-item2 item">
  156. <div class="arr-l">
  157. <div class="arr-l-t">
  158. <div class="arr-l-t-t" />
  159. <el-select v-model="element.tmrid" placeholder="撒料设备" class="arr-l-t-b el-icon-arrow-down" @change="(value)=> {changeEquipment(value, scope.row,element.fttype,element.id)}">
  160. <el-option v-for="item in equipmentList" :key="item.id" :label="item.tmrmix" :value="item.id" />
  161. </el-select>
  162. </div>
  163. <div class="arr-l-b">
  164. <el-tooltip placement="top" class="list-group-item1 item" style="height: 18px;line-height: 18px;">
  165. <div slot="content">{{ element.tmrname }}</div>
  166. <div class="tmrname">{{ element.tmrname }}</div>
  167. </el-tooltip>
  168. </div>
  169. </div>
  170. <div class="arr-r">
  171. <div class="arr-r-l">
  172. <el-tooltip placement="top">
  173. <div slot="content">{{ element.barname }}</div>
  174. <div class="barname">{{ element.barname }}</div>
  175. </el-tooltip>
  176. </div>
  177. <div class="arr-r-c">-</div>
  178. <div class="arr-r-r">
  179. <el-tooltip v-show="!element.isWeight" placement="top">
  180. <div slot="content">{{ element.weight }}</div>
  181. <div class="weight" @dblclick="dbclickWeight(element)">{{ element.weight }}</div>
  182. </el-tooltip>
  183. <el-tooltip v-show="element.isWeight" placement="top">
  184. <div slot="content">{{ element.weight }}</div>
  185. <input ref="weight" v-model="element.weight" v-focus="element.focusState" type="number" placeholder="重量" step="0.01" class="filter-item2" style="display: inline-block;height:16px;padding:4px 0px; font-size:12px;width: 95%;border: 1px solid #e6e6e6;" @blur="(value)=> {blurWeight(scope.row,element.fttype,element.id)}">
  186. </el-tooltip>
  187. </div>
  188. </div>
  189. <div class="arr-t" :style="{'background':element.background}">
  190. <i class="el-icon-close" style="position: absolute;right: 0;" @click="handleFLDelete(element,scope.row)" />
  191. </div>
  192. </div>
  193. </draggable>
  194. </template>
  195. </el-table-column>
  196. <el-table-column label="操作" align="center" width="80" class-name="small-padding fixed-width" fixed="right">
  197. <template slot-scope="{row}">
  198. <el-button v-if="row.isCreate" :disabled="isokDisable" icon="el-icon-folder-checked" class="miniSuccess" @click="createData(row)" />
  199. <span v-if="row.isCreate" class="centerSpan">|</span>
  200. <el-button v-if="row.isCreate" class="minCancel" icon="el-icon-close" @click="createCancel(row)" />
  201. <el-button v-if="row.isUpdate" class="miniSuccess" icon="el-icon-edit-outline" @click="handleUpdate(row)" />
  202. <span v-if="row.isUpdate" class="centerSpan">|</span>
  203. <el-button v-if="row.isUpdate" class="miniDanger" icon="el-icon-delete" @click="handleRowDelete(row)" />
  204. <el-button v-if="row.isUpdateSave" :disabled="isokDisable" icon="el-icon-folder-checked" class="miniSuccess" @click="updateData(row)" />
  205. <span v-if="row.isUpdateSave" class="centerSpan">|</span>
  206. <el-button v-if="row.isUpdateSave" class="minCancel" icon="el-icon-close" @click="updateCancel(row)" />
  207. </template>
  208. </el-table-column>
  209. </el-table>
  210. </div>
  211. <!-- 自动生成 -->
  212. <el-dialog :title="textMap[automaticGeneration.dialogStatus]" :destroy-on-close="true" :visible.sync="automaticGeneration.dialogFormVisible" :close-on-click-modal="false" width="30%">
  213. <div class="app-automaticGeneration" style="margin: 0 auto;">
  214. <div style="width: 210px;margin:60px auto 120px;font-weight: 16px;">
  215. 请选择自动生成方式:<br>
  216. 清空计划并生成新计划;<br>
  217. 当前计划基础上继续生成计划;<br>
  218. </div>
  219. <div slot="footer" class="dialog-footer">
  220. <el-button class="cancelClose" @click="automaticGeneration.dialogFormVisible = false; ">关闭</el-button>
  221. <el-button class="save" :disabled="isokDisable" @click="continueData(0)">继续生成</el-button>
  222. <el-button class="save" :disabled="isokDisable" @click="continueData(1)">重新生成</el-button>
  223. </div>
  224. </div>
  225. </el-dialog>
  226. <!-- 历史记录 -->
  227. <el-dialog :title="textMap[historyRecord.dialogStatus]" :destroy-on-close="true" :visible.sync="historyRecord.dialogFormVisible" :close-on-click-modal="false" width="90%">
  228. <div class="historyRecord">
  229. <keep-alive>
  230. <component :is="historyRecord.myComponent" ref="historyRecord" />
  231. </keep-alive>
  232. </div>
  233. <div slot="footer" class="dialog-footer" style="bottom: 10px;">
  234. <el-button class="cancelClose" @click="historyRecord.dialogFormVisible = false; ">关闭</el-button>
  235. </div>
  236. </el-dialog>
  237. </div>
  238. </div>
  239. </div>
  240. </template>
  241. <script>
  242. import { GetDataByName, GetArrList, PostDataByName, failproccess, ExecDataByConfig } from '@/api/common'
  243. import draggable from 'vuedraggable'
  244. import Sortable from 'sortablejs'
  245. import Cookies from 'js-cookie'
  246. import { MessageBox } from 'element-ui'
  247. // const id = 1
  248. export default {
  249. name: 'MaterialIssuancePlan',
  250. display: 'Two list header slot',
  251. order: 14,
  252. components: { draggable },
  253. directives: {
  254. focus: {
  255. update: function(el, { value }) {
  256. if (value) {
  257. el.focus()
  258. }
  259. }
  260. }
  261. },
  262. data() {
  263. return {
  264. isBarracks: false,
  265. requestParams: {
  266. name: 'getTMRListEnableType', offset: 0, parammaps: { pastureid: Cookies.get('pastureid'), eqtype: '1' }
  267. },
  268. requestParams2: {
  269. name: 'getTMRListEnableTypeAll', offset: 0, parammaps: { pastureid: Cookies.get('pastureid'), eqtype: '1' }
  270. },
  271. requestParams3: {
  272. name: 'getFTSWList', offset: 0, parammaps: { pastureid: Cookies.get('pastureid') }
  273. },
  274. equipmentList: [], // 撒料设备
  275. TMRNumberList: [], // TMR编号
  276. frequencyList: [], // 班次
  277. templateFormulationList: [], // 模板配方
  278. // 班次
  279. maxTime: {
  280. getMaxTimesParm: {
  281. name: 'getSysoptEnable',
  282. page: 1,
  283. offset: 1,
  284. pagecount: 1,
  285. returntype: 'Map',
  286. parammaps: {
  287. pastureid: Cookies.get('pastureid'),
  288. inforname: 'times'
  289. }
  290. },
  291. // 班次
  292. isTime1: false,
  293. isTime2: false,
  294. isTime3: false,
  295. isTime4: false
  296. },
  297. table: {
  298. getdataListParm: {
  299. name: 'getLppList',
  300. name1: 'getLppdList',
  301. page: 1,
  302. offset: 1,
  303. returntype: 'Map',
  304. parammaps: {
  305. pastureid: Cookies.get('pastureid')
  306. }
  307. },
  308. list: [],
  309. total: 0,
  310. tableKey: 0,
  311. listLoading: false,
  312. tabClickIndex: null, // 点击的单元格
  313. tabClickLabel: '', // 当前点击的列名
  314. temp: {},
  315. move1: '',
  316. changeList: [],
  317. startObj: {},
  318. isGoing: false
  319. },
  320. selectList: [], // 选中数据
  321. // 班次
  322. menuRadio: '一班',
  323. MenuList: [], // 配单列表
  324. getdataListParmTimes: {
  325. name: 'geFTListByFP',
  326. name1: 'geFTListByFPDetail',
  327. page: 1,
  328. offset: 1,
  329. returntype: 'Map',
  330. parammaps: {
  331. pastureid: Cookies.get('pastureid'),
  332. times: '1'
  333. }
  334. },
  335. listLoadingTimes: false,
  336. // 栏舍统计
  337. isLeftButton: true, // 向左
  338. isRightButton: false, // 向右
  339. rowStyle2: { maxHeight: 20 + 'px', height: 20 + 'px' },
  340. cellStyle2: { padding: 0 + 'px' },
  341. headerRowStyle2: { maxHeight: 20 + 'px', height: 20 + 'px' },
  342. headerCellStyle2: { padding: 0 + 'px' },
  343. smallMenu: {
  344. getdataListParm: {
  345. name: 'getLppUseSUMList',
  346. page: 1,
  347. offset: 1,
  348. pagecount: 10,
  349. returntype: 'Map',
  350. parammaps: {
  351. pastureid: Cookies.get('pastureid')
  352. }
  353. },
  354. total: 0,
  355. tableKey: 0,
  356. listLoading: false,
  357. list: []
  358. },
  359. // 自动生成
  360. automaticGeneration: {
  361. dialogFormVisible: false,
  362. dialogStatus: ''
  363. },
  364. historyRecord: {
  365. dialogFormVisible: false,
  366. dialogStatus: '',
  367. myComponent: null
  368. },
  369. textMap: {
  370. automaticGeneration: '提示',
  371. historyRecord: '历史记录'
  372. },
  373. isokDisable: false,
  374. requestParam: {},
  375. height: document.body.clientHeight - 210 - 50, // table高度
  376. rowStyle: { maxHeight: 30 + 'px', height: 30 + 'px' },
  377. cellStyle: { padding: 0 + 'px' },
  378. dropState: false,
  379. isOrder: true
  380. }
  381. },
  382. created() {
  383. this.getIsDisplay()
  384. this.getDownList()
  385. },
  386. methods: {
  387. clickBarracks(item) {
  388. this.isBarracks = !this.isBarracks
  389. },
  390. // 下拉列表
  391. getDownList() {
  392. GetDataByName(this.requestParams).then(response => {
  393. if (response.data !== null) {
  394. this.TMRNumberList = response.data.list
  395. } else {
  396. this.TMRNumberList = []
  397. }
  398. })
  399. GetDataByName(this.requestParams2).then(response => {
  400. if (response.data !== null) {
  401. this.equipmentList = response.data.list
  402. } else {
  403. this.equipmentList = []
  404. }
  405. })
  406. GetDataByName(this.requestParams3).then(response => {
  407. if (response.data !== null) {
  408. this.templateFormulationList = response.data.list
  409. } else {
  410. this.templateFormulationList = []
  411. }
  412. })
  413. },
  414. // 显示班次
  415. getIsDisplay() {
  416. GetDataByName(this.maxTime.getMaxTimesParm).then(response => {
  417. console.log(response.data.list[0].inforvalue)
  418. if (response.data.list[0].inforvalue == 1) {
  419. this.frequencyList = [{ id: '1', name: '第一班' }]
  420. } else if (response.data.list[0].inforvalue == 2) {
  421. this.frequencyList = [{ id: '1', name: '第一班' }, { id: '2', name: '第二班' }]
  422. } else if (response.data.list[0].inforvalue == 3) {
  423. this.frequencyList = [{ id: '1', name: '第一班' }, { id: '2', name: '第二班' }, { id: '3', name: '第三班' }]
  424. } else if (response.data.list[0].inforvalue == 4) {
  425. this.frequencyList = [{ id: '1', name: '第一班' }, { id: '2', name: '第二班' }, { id: '3', name: '第三班' }, { id: '4', name: '第四班' }]
  426. }
  427. if (response.data.list !== null) {
  428. if (response.data.list[0].inforvalue == 1) {
  429. this.maxTime.isTime1 = true
  430. this.maxTime.isTime2 = false
  431. this.maxTime.isTime3 = false
  432. this.maxTime.isTime4 = false
  433. } else if (response.data.list[0].inforvalue == 2) {
  434. this.maxTime.isTime1 = true
  435. this.maxTime.isTime2 = true
  436. this.maxTime.isTime3 = false
  437. this.maxTime.isTime4 = false
  438. } else if (response.data.list[0].inforvalue == 3) {
  439. this.maxTime.isTime1 = true
  440. this.maxTime.isTime2 = true
  441. this.maxTime.isTime3 = true
  442. this.maxTime.isTime4 = false
  443. } else if (response.data.list[0].inforvalue == 4) {
  444. this.maxTime.isTime1 = true
  445. this.maxTime.isTime2 = true
  446. this.maxTime.isTime3 = true
  447. this.maxTime.isTime4 = true
  448. }
  449. } else {
  450. this.maxTime.isTime1 = false
  451. this.maxTime.isTime2 = false
  452. this.maxTime.isTime3 = false
  453. this.maxTime.isTime4 = false
  454. }
  455. })
  456. this.getList()
  457. this.getSmallMenuList() // 栏舍统计
  458. this.getTimesList() // 班次
  459. },
  460. // 头部班次
  461. getTimesList() {
  462. this.listLoadingTimes = true
  463. GetArrList(this.getdataListParmTimes).then(response => {
  464. if (response.data.list !== null) {
  465. for (let i = 0; i < response.data.list.length; i++) {
  466. this.$set(response.data.list[i], 'isShowTitle', true)
  467. if (response.data.list[i].arrList == null) {
  468. this.$set(response.data.list[i], 'isShowTitle', false)
  469. } else {
  470. for (let j = 0; j < response.data.list[i].arrList.length; j++) {
  471. this.$set(response.data.list[i].arrList[j], 'background2', this.colorRgb(response.data.list[i].arrList[j].background))
  472. }
  473. }
  474. // console.log(response.data.list[i])
  475. }
  476. this.MenuList = response.data.list
  477. } else {
  478. this.MenuList = []
  479. }
  480. })
  481. setTimeout(() => {
  482. this.listLoadingTimes = false
  483. }, 100)
  484. },
  485. colorRgb(sColor) {
  486. sColor = sColor.toLowerCase()
  487. var reg = /^#([0-9a-fA-f]{3}|[0-9a-fA-f]{6})$/
  488. // 如果是16进制颜色
  489. if (sColor && reg.test(sColor)) {
  490. if (sColor.length === 4) {
  491. var sColorNew = '#'
  492. for (var i = 1; i < 4; i += 1) {
  493. sColorNew += sColor.slice(i, i + 1).concat(sColor.slice(i, i + 1))
  494. }
  495. sColor = sColorNew
  496. }
  497. // 处理六位的颜色值
  498. var sColorChange = []
  499. for (var i = 1; i < 7; i += 2) {
  500. sColorChange.push(parseInt('0x' + sColor.slice(i, i + 2)))
  501. }
  502. return sColorChange.join(',')
  503. }
  504. return 'rgba(' + sColorChange.join(',') + ')'
  505. },
  506. // 切换班次
  507. changeMenu(val) {
  508. console.log(val)
  509. if (this.menuRadio === '一班') {
  510. this.getdataListParmTimes.parammaps.times = '1'
  511. this.getTimesList()
  512. } else if (this.menuRadio === '二班') {
  513. this.getdataListParmTimes.parammaps.times = '2'
  514. this.getTimesList()
  515. this.MenuList = this.twoMenuList
  516. } else if (this.menuRadio === '三班') {
  517. this.getdataListParmTimes.parammaps.times = '3'
  518. this.getTimesList()
  519. } else if (this.menuRadio === '四班') {
  520. this.getdataListParmTimes.parammaps.times = '4'
  521. this.getTimesList()
  522. }
  523. },
  524. // 右侧栏舍统计
  525. getSmallMenuList() {
  526. this.smallMenu.listLoading = true
  527. GetDataByName(this.smallMenu.getdataListParm).then(response => {
  528. if (response.data.list !== null) {
  529. for (let i = 0; i < response.data.list.length; i++) {
  530. if (response.data.list[i].onetime == undefined) { this.$set(response.data.list[i], 'onetime', 0) } else { response.data.list[i].onetime = parseFloat(response.data.list[i].onetime) }
  531. if (response.data.list[i].twotime == undefined) { this.$set(response.data.list[i], 'twotime', 0) } else { response.data.list[i].twotime = parseFloat(response.data.list[i].twotime) }
  532. if (response.data.list[i].threetime == undefined) { this.$set(response.data.list[i], 'threetime', 0) } else { response.data.list[i].threetime = parseFloat(response.data.list[i].threetime) }
  533. if (response.data.list[i].fourtime == undefined) { this.$set(response.data.list[i], 'fourtime', 0) } else { response.data.list[i].fourtime = parseFloat(response.data.list[i].fourtime) }
  534. this.$set(response.data.list[i], 'usedsum', response.data.list[i].onetime + response.data.list[i].twotime + response.data.list[i].threetime + response.data.list[i].fourtime)
  535. this.$set(response.data.list[i], 'all', '')
  536. }
  537. this.smallMenu.list = response.data.list
  538. this.smallMenu.total = response.data.total
  539. } else {
  540. this.smallMenu.list = []
  541. }
  542. console.log('smallMenu数据', response.data.list)
  543. setTimeout(() => {
  544. this.smallMenu.listLoading = false
  545. }, 100)
  546. })
  547. },
  548. // table
  549. getList() {
  550. this.table.listLoading = true
  551. GetArrList(this.table.getdataListParm).then(response => {
  552. if (response.data.list !== null) {
  553. console.log('table数据', response.data.list)
  554. for (let i = 0; i < response.data.list.length; i++) {
  555. this.$set(response.data.list[i], 'Edit', false) // 编辑
  556. this.$set(response.data.list[i], 'NoEdit', true) // 不可编辑/输入
  557. this.$set(response.data.list[i], 'isCreate', false) // 新增操作
  558. this.$set(response.data.list[i], 'isUpdate', true) // 编辑操作
  559. this.$set(response.data.list[i], 'isUpdateSave', false) // 编辑保存
  560. this.$set(response.data.list[i], 'Disabled', true) // 班次/模板配方不可输入
  561. if (response.data.list[i].arrList == null) {
  562. this.$set(response.data.list[i], 'Disabled', false)
  563. this.$set(response.data.list[i], 'arrList', [])
  564. } else {
  565. for (let j = 0; j < response.data.list[i].arrList.length; j++) {
  566. this.$set(response.data.list[i].arrList[j], 'isWeight', false)
  567. this.$set(response.data.list[i].arrList[j], 'focusState', false)
  568. }
  569. }
  570. }
  571. this.table.list = response.data.list
  572. // this.rowDrop()
  573. this.table.changeList = []
  574. this.table.startObj = {}
  575. if (response.data.total) {
  576. this.table.total = response.data.total
  577. }
  578. } else {
  579. this.table.list = []
  580. }
  581. setTimeout(() => {
  582. this.table.listLoading = false
  583. }, 100)
  584. })
  585. },
  586. handleChangeOrder() {
  587. this.isOrder = false
  588. this.rowDrop()
  589. },
  590. // 行拖拽
  591. rowDrop() {
  592. console.log(document.querySelector('#table .el-table__body-wrapper tbody'))
  593. const tbody = document.querySelector('#table .el-table__body-wrapper tbody')
  594. const that = this
  595. var sortable = Sortable.create(tbody, {
  596. disabled: that.dropState,
  597. onChoose({ newIndex, oldIndex }) {
  598. console.log(that.isOrder, 'that.isOrder == false')
  599. console.log(that.dropState, 'that.dropState')
  600. if (that.dropState == true || that.isOrder == true) {
  601. sortable.destroy()
  602. }
  603. },
  604. onEnd({ newIndex, oldIndex }) {
  605. const currRow = that.table.list.splice(oldIndex, 1)[0]
  606. that.table.list.splice(newIndex, 0, currRow)
  607. console.log('索引', newIndex)
  608. console.log('拖动数据', currRow)
  609. console.log('上', that.table.list[newIndex - 1])
  610. console.log('下', that.table.list[newIndex + 1])
  611. }
  612. })
  613. },
  614. saveChangeOrder() {
  615. // 保存顺序
  616. var sortArr = []
  617. for (let i = 0; i < this.table.list.length; i++) {
  618. var obj = {}
  619. obj.sort = i + 1
  620. obj.id = this.table.list[i].id
  621. obj.pastureid = this.table.list[i].pastureid
  622. sortArr.push(obj)
  623. }
  624. this.requestParam = {}
  625. this.requestParam.common = { 'returnmap': '0' }
  626. this.requestParam.data = []
  627. this.requestParam.data[0] = { 'name': 'insertSpotList', 'resultmaps': { 'list': sortArr }}
  628. this.requestParam.data[0].children = []
  629. this.requestParam.data[0].children[0] = { 'name': 'updateLppSort', 'type': 'e', 'parammaps': {
  630. id: '@insertSpotList.id',
  631. pastureid: '@insertSpotList.pastureid',
  632. sort: '@insertSpotList.sort'
  633. }}
  634. ExecDataByConfig(this.requestParam).then(response => {
  635. console.log('顺序切换保存发送参数', this.requestParam)
  636. if (response.msg === 'fail') {
  637. this.$notify({ title: '顺序切换失败', message: response.data, type: 'warning', duration: 2000 })
  638. } else {
  639. this.$notify({ title: '', message: '顺序切换成功', type: 'success', duration: 2000 })
  640. this.getList()
  641. this.isOrder = true
  642. }
  643. })
  644. },
  645. cancelChangeOrder() {
  646. // 取消顺序
  647. this.getList()
  648. this.isOrder = true
  649. },
  650. // TMR编号
  651. changeTMRNumber(item, row) {
  652. row.tmrname = this.TMRNumberList.find(obj => obj.id === item).eqcode
  653. row.maxweight = this.TMRNumberList.find(obj => obj.id === item).maxstirfeed
  654. },
  655. // 配方模板
  656. changeTemplateFormulation(item, row) {
  657. row.ftname = this.templateFormulationList.find(obj => obj.id === item).tname
  658. },
  659. // 增加车次
  660. handleCreate() {
  661. console.log(this.table.list)
  662. for (let i = 0; i < this.table.list.length; i++) {
  663. if (this.table.list[i].Edit === true) {
  664. this.$message({ type: 'error', message: '当前内容未保存,请点击取消或保存继续进行操作', duration: 2000 })
  665. return false
  666. }
  667. }
  668. if (this.table.list.length == 0) {
  669. this.table.list.unshift({ 'myId': (new Date()).valueOf(), 'Edit': true, 'NoEdit': false, 'isCreate': true, 'isUpdate': false, 'isUpdateSave': false, 'tmrname': '', 'tmrid': '', 'sort': 1, 'sel': 1, 'issplit': 1, 'times': '', 'display': '', 'begintime': '', 'ftname': '', 'ftid': '', 'sumweight': '', 'sumcowcount': '', 'maxweight': '', 'arrList': [] })
  670. } else {
  671. this.table.list.unshift({ 'myId': (new Date()).valueOf(), 'Edit': true, 'NoEdit': false, 'isCreate': true, 'isUpdate': false, 'isUpdateSave': false, 'tmrname': '', 'tmrid': '', 'sort': parseInt(this.table.list[this.table.list.length - 1].sort) + 1, 'sel': 1, 'issplit': 1, 'times': '', 'display': '', 'begintime': '', 'ftname': '', 'ftid': '', 'sumweight': '', 'sumcowcount': '', 'maxweight': '', 'arrList': [] })
  672. }
  673. // this.$refs.box.scrollTop = 0
  674. this.$refs.table.bodyWrapper.scrollTop = 0
  675. this.dropState = true
  676. },
  677. createData(row) {
  678. console.log('点击了新增保存', row)
  679. if (row.begintime == null || row.begintime == 'null') {
  680. row.begintime = ''
  681. }
  682. this.table.temp.pastureid = Cookies.get('pastureid')
  683. this.table.temp.tmrname = row.tmrname
  684. this.table.temp.tmrid = row.tmrid
  685. this.table.temp.sort = row.sort
  686. this.table.temp.sel = row.sel
  687. this.table.temp.issplit = row.issplit
  688. this.table.temp.times = row.times
  689. this.table.temp.display = row.display
  690. this.table.temp.begintime = row.begintime
  691. this.table.temp.ftname = row.ftname
  692. this.table.temp.ftid = row.ftid
  693. this.table.temp.sumweight = 0
  694. this.table.temp.maxweight = row.maxweight
  695. if (this.table.temp.sort == '' && this.table.temp.tmrid == '' && this.table.temp.times == '' && this.table.temp.ftid == '') {
  696. this.$message({ type: 'error', message: '车次/TMR编号/班次/模板配方不能为空', duration: 2000 })
  697. return false
  698. } else if (this.table.temp.tmrid == '' && this.table.temp.times == '' && this.table.temp.ftid == '') {
  699. this.$message({ type: 'error', message: 'TMR编号/班次/模板配方不能为空', duration: 2000 })
  700. return false
  701. } else if (this.table.temp.times == '' && this.table.temp.ftid == '') {
  702. this.$message({ type: 'error', message: '班次/模板配方不能为空', duration: 2000 })
  703. return false
  704. } else if (this.table.temp.ftid == '') {
  705. this.$message({ type: 'error', message: '模板配方不能为空', duration: 2000 })
  706. return false
  707. } else if (this.table.temp.times == '') {
  708. this.$message({ type: 'error', message: '班次不能为空', duration: 2000 })
  709. return false
  710. }
  711. for (let i = 0; i < this.table.list.length; i++) {
  712. if (row.sort == this.table.list[i].sort) {
  713. if (row.myId !== this.table.list[i].myId) {
  714. this.$message({ type: 'error', message: '车次不可重复', duration: 2000 })
  715. return false
  716. }
  717. }
  718. }
  719. var isInteger = /^\d+$/
  720. if (this.table.temp.sort !== '') {
  721. if (!isInteger.test(parseFloat(this.table.temp.sort))) {
  722. this.$message({ type: 'error', message: '车次请输入整数', duration: 2000 })
  723. return false
  724. }
  725. }
  726. this.isokDisable = true
  727. setTimeout(() => {
  728. this.isokDisable = false
  729. }, 1000)
  730. this.requestParam = {}
  731. this.requestParam.name = 'insertLpp'
  732. this.requestParam.parammaps = this.table.temp
  733. PostDataByName(this.requestParam).then(response => {
  734. console.log('新增保存发送参数', this.requestParam)
  735. if (response.msg !== 'fail') {
  736. this.$notify({ title: '成功', message: '保存成功', type: 'success', duration: 2000 })
  737. this.getList()
  738. this.dropState = false
  739. } else {
  740. this.$notify({ title: '保存失败', message: response.data, type: 'warning', duration: 2000 })
  741. }
  742. })
  743. },
  744. createCancel(row) {
  745. console.log('点击了新增取消')
  746. this.dropState = false
  747. for (let i = 0; i < this.table.list.length; i++) {
  748. if (row.myId === this.table.list[i].myId) {
  749. var listIndex = this.table.list.indexOf(this.table.list[i])
  750. }
  751. if (listIndex > -1) {
  752. this.table.list.splice(listIndex, 1)
  753. return
  754. }
  755. }
  756. },
  757. // 编辑
  758. handleUpdate(row) {
  759. console.log(row, '点击了行编辑')
  760. for (let i = 0; i < this.table.list.length; i++) {
  761. if (this.table.list[i].Edit == true) {
  762. this.$message({ type: 'error', message: '当前内容未保存,请点击取消或保存继续进行操作', duration: 2000 })
  763. return false
  764. }
  765. }
  766. // 编辑true,不可编辑false
  767. row.Edit = true
  768. row.NoEdit = false
  769. // 新增false,编辑false,编辑保存true
  770. row.isCreate = false
  771. row.isUpdate = false
  772. row.isUpdateSave = true
  773. row.times = String(row.times)
  774. if (row.sort == undefined) { row.sort = '' }
  775. if (row.tmrid == undefined || row.tmrname == undefined) {
  776. row.tmrid = ''
  777. row.tmrname = ''
  778. }
  779. if (row.display == undefined) { row.display = '' }
  780. if (row.times == undefined) { row.times = '' }
  781. if (row.begintime == undefined) { row.begintime = '' }
  782. if (row.ftid == undefined || row.ftname == undefined) {
  783. row.ftid = ''
  784. row.ftname = ''
  785. }
  786. this.dropState = true
  787. },
  788. updateData(row) {
  789. console.log('点击了编辑保存', row)
  790. if (row.begintime == null || row.begintime == 'null') {
  791. row.begintime = ''
  792. }
  793. this.table.temp.pastureid = row.pastureid
  794. this.table.temp.id = row.id
  795. this.table.temp.tmrname = row.tmrname
  796. this.table.temp.tmrid = row.tmrid
  797. this.table.temp.sort = row.sort
  798. this.table.temp.sel = row.sel
  799. this.table.temp.issplit = row.issplit
  800. this.table.temp.times = row.times
  801. this.table.temp.display = row.display
  802. this.table.temp.begintime = row.begintime
  803. this.table.temp.ftname = row.ftname
  804. this.table.temp.ftid = row.ftid
  805. this.table.temp.sumweight = row.sumweight
  806. this.table.temp.sumcowcount = row.sumcowcount
  807. this.table.temp.maxweight = row.maxweight
  808. if (this.table.temp.sort == '' && this.table.temp.tmrid == '' && this.table.temp.times == '' && this.table.temp.ftid == '') {
  809. this.$message({ type: 'error', message: '车次/TMR编号/班次/模板配方不能为空', duration: 2000 })
  810. return false
  811. } else if (this.table.temp.tmrid == '' && this.table.temp.times == '' && this.table.temp.ftid == '') {
  812. this.$message({ type: 'error', message: 'TMR编号/班次/模板配方不能为空', duration: 2000 })
  813. return false
  814. } else if (this.table.temp.times == '' && this.table.temp.ftid == '') {
  815. this.$message({ type: 'error', message: '班次/模板配方不能为空', duration: 2000 })
  816. return false
  817. } else if (this.table.temp.ftid == '') {
  818. this.$message({ type: 'error', message: '模板配方不能为空', duration: 2000 })
  819. return false
  820. }
  821. for (let i = 0; i < this.table.list.length; i++) {
  822. if (row.sort == this.table.list[i].sort) {
  823. if (row.id !== this.table.list[i].id) {
  824. this.$message({ type: 'error', message: '车次不可重复', duration: 2000 })
  825. return false
  826. }
  827. }
  828. }
  829. var isInteger = /^\d+$/
  830. if (this.table.temp.sort !== '') {
  831. if (!isInteger.test(parseFloat(this.table.temp.sort))) {
  832. this.$message({ type: 'error', message: '车次请输入整数', duration: 2000 })
  833. return false
  834. }
  835. }
  836. this.isokDisable = true
  837. setTimeout(() => {
  838. this.isokDisable = false
  839. }, 1000)
  840. this.requestParam = {}
  841. this.requestParam.name = 'updateLpp'
  842. this.requestParam.parammaps = this.table.temp
  843. PostDataByName(this.requestParam).then(response => {
  844. console.log('编辑保存发送参数', this.requestParam)
  845. if (response.msg !== 'fail') {
  846. this.$notify({ title: '成功', message: '保存成功', type: 'success', duration: 2000 })
  847. this.getList()
  848. this.dropState = false
  849. } else {
  850. this.$notify({ title: '保存失败', message: response.data, type: 'warning', duration: 2000 })
  851. }
  852. })
  853. },
  854. updateCancel(row) {
  855. console.log('点击了编辑取消')
  856. // 编辑false,不可编辑true
  857. row.Edit = false
  858. row.NoEdit = true
  859. // 新增false,编辑true,编辑保存false
  860. row.isCreate = false
  861. row.isUpdate = true
  862. row.isUpdateSave = false
  863. this.dropState = false
  864. this.getList()
  865. },
  866. // 自动生成
  867. handleAutomaticGeneration() {
  868. this.automaticGeneration.dialogStatus = 'automaticGeneration'
  869. this.automaticGeneration.dialogFormVisible = true
  870. },
  871. continueData(item) {
  872. if (item == 0) {
  873. console.log('点击继续生成')
  874. this.requestParam = {}
  875. this.requestParam.common = { 'returnmap': '0' }
  876. this.requestParam.data = []
  877. this.requestParam.data[0] = { 'name': 'autoCreateLPP', 'type': 'e', 'parammaps': {
  878. 'pastureid': Cookies.get('pastureid'),
  879. 'type': 0
  880. }}
  881. ExecDataByConfig(this.requestParam).then(response => {
  882. console.log('保存发送参数', this.requestParam)
  883. if (response.msg === 'fail') {
  884. this.$notify({ title: '保存失败', message: response.data, type: 'warning', duration: 2000 })
  885. } else {
  886. this.$notify({ title: '', message: '保存成功', type: 'success', duration: 2000 })
  887. this.automaticGeneration.dialogFormVisible = false
  888. this.getIsDisplay()
  889. this.getDownList()
  890. }
  891. })
  892. } else {
  893. console.log('点击重新生成')
  894. this.requestParam = {}
  895. this.requestParam.common = { 'returnmap': '0' }
  896. this.requestParam.data = []
  897. this.requestParam.data[0] = { 'name': 'autoCreateLPP', 'type': 'e', 'parammaps': {
  898. 'pastureid': Cookies.get('pastureid'),
  899. 'type': 1
  900. }}
  901. ExecDataByConfig(this.requestParam).then(response => {
  902. console.log('保存发送参数', this.requestParam)
  903. if (response.msg === 'fail') {
  904. this.$notify({ title: '保存失败', message: response.data, type: 'warning', duration: 2000 })
  905. } else {
  906. this.$notify({ title: '', message: '保存成功', type: 'success', duration: 2000 })
  907. this.automaticGeneration.dialogFormVisible = false
  908. this.getIsDisplay()
  909. this.getDownList()
  910. }
  911. })
  912. }
  913. },
  914. // 检验
  915. // handleCheck() {
  916. // console.log('点击检验')
  917. // },
  918. // 历史记录
  919. handleHistoryRecord() {
  920. console.log('点击历史记录')
  921. this.historyRecord.dialogStatus = 'historyRecord'
  922. this.historyRecord.dialogFormVisible = true
  923. const vue = this
  924. var myComponent = () => import('./historyRecord.vue')
  925. return vue.historyRecord.myComponent = myComponent
  926. },
  927. // 配方
  928. changeLog: function(evt) {
  929. console.log('change1', evt)
  930. },
  931. start(evt) {
  932. console.log('start1', evt)
  933. this.$set(this.table.startObj, 'from', evt.from.className)
  934. this.$set(this.table.startObj, 'to', evt.from.className)
  935. },
  936. end(evt) {
  937. console.log('end1', evt)
  938. },
  939. move(evt, originalEvent) {
  940. if (originalEvent.target.className === 'list-group-item1 item' || originalEvent.target.className === 'draggableWeight') {
  941. return false
  942. }
  943. console.log(evt)
  944. this.table.move1 = evt.draggedContext.element
  945. },
  946. start2(evt) {
  947. console.log('start2', evt)
  948. this.$set(this.table.startObj, 'from', evt.from.className)
  949. this.$set(this.table.startObj, 'to', evt.from.className)
  950. },
  951. move2(evt, originalEvent) {
  952. // console.log(evt, originalEvent)
  953. if (originalEvent.target.className === 'list-group-item1 item' || originalEvent.target.className === 'draggableWeight') {
  954. return false
  955. }
  956. this.table.move1 = evt.draggedContext.element
  957. },
  958. end2(evt) {
  959. // console.log(evt)
  960. console.log('end2', evt)
  961. },
  962. // 撒料位
  963. changeLog2(evt) {
  964. // console.log(this.table.startObj)
  965. console.log(evt, 'evt-----')
  966. // var _evt = [...evt]
  967. this.table.changeList.push(evt)
  968. evt = this.table.changeList[0]
  969. if (evt.arrList.length == 1) {
  970. evt.arrList[0].sort = 0
  971. } else if (evt.arrList.length > 1) {
  972. for (let i = 0; i < evt.arrList.length; i++) {
  973. if (evt.arrList[i].id == this.table.move1.id && evt.arrList[i].fttype == this.table.move1.fttype) {
  974. if (evt.arrList[i - 1] == undefined) {
  975. evt.arrList[i].sort = 0
  976. evt.sort = 0
  977. } else {
  978. evt.arrList[i].sort = parseFloat(evt.arrList[i - 1].sort) + 1
  979. evt.sort = parseFloat(evt.arrList[i - 1].sort) + 1
  980. }
  981. }
  982. }
  983. }
  984. console.log(evt.arrList, '==========1')
  985. console.log(evt, '==========2')
  986. console.log(this.table.move1.times, 'this.table.move1.times-------')
  987. if (this.table.startObj.from == 'list-group1' && this.table.startObj.to == 'list-group1') {
  988. this.requestParam = {}
  989. this.requestParam.common = { 'returnmap': '0' }
  990. this.requestParam.data = []
  991. this.requestParam.data[0] = { 'name': 'checkLLPDetailInsert', 'type': 'v', 'parammaps': {
  992. pastureid: this.table.move1.pastureid,
  993. barid: this.table.move1.barid,
  994. lppid: evt.id,
  995. times: evt.times,
  996. ftid: this.table.move1.ftid,
  997. ptsid: this.table.move1.ptsid,
  998. ptid: this.table.move1.ptid,
  999. fttype: this.table.move1.fttype,
  1000. timesTem: this.table.move1.times
  1001. }}
  1002. this.requestParam.data[1] = { 'name': 'updateLpplandtlSorts', 'type': 'e', 'parammaps': {
  1003. pastureid: evt.pastureid,
  1004. sort: evt.sort,
  1005. lppid: evt.id
  1006. }}
  1007. this.requestParam.data[2] = { 'name': 'insertLppd', 'type': 'e', 'parammaps': {
  1008. pastureid: evt.pastureid,
  1009. lppid: evt.id,
  1010. barid: this.table.move1.barid,
  1011. barname: this.table.move1.barname,
  1012. fpdid: this.table.move1.id,
  1013. fttype: this.table.move1.fttype,
  1014. lweight: this.table.move1.weight,
  1015. sort: evt.sort,
  1016. tmrid: evt.tmrid,
  1017. tmrname: evt.tmrname,
  1018. background: this.table.move1.background,
  1019. ccountradio: this.table.move1.ccountradio,
  1020. cowcount: this.table.move1.cowcount
  1021. }}
  1022. this.requestParam.data[3] = { 'name': 'updateFpdetailUse', 'type': 'e', 'parammaps': {
  1023. pastureid: this.table.move1.pastureid,
  1024. id: this.table.move1.id,
  1025. fttype: this.table.move1.fttype,
  1026. lweight: this.table.move1.weight
  1027. }}
  1028. console.log('撒料位上-下新增', this.requestParam)
  1029. ExecDataByConfig(this.requestParam).then(response => {
  1030. console.log('撒料位新增保存发送参数', this.requestParam)
  1031. if (response.msg === 'fail') {
  1032. this.$notify({ title: '保存失败', message: response.data, type: 'warning', duration: 2000 })
  1033. this.getTimesList()
  1034. this.getSmallMenuList()
  1035. this.getList()
  1036. } else {
  1037. this.$notify({ title: '', message: '保存成功', type: 'success', duration: 2000 })
  1038. this.getIsDisplay()
  1039. }
  1040. })
  1041. } else if (this.table.startObj.from == 'list-group2' && this.table.startObj.to == 'list-group2') {
  1042. if (this.table.changeList.length == 1) {
  1043. this.requestParam = {}
  1044. this.requestParam.common = { 'returnmap': '0' }
  1045. this.requestParam.data = []
  1046. this.requestParam.data[0] = { 'name': 'checkLLPDetailInsert', 'type': 'v', 'parammaps': {
  1047. pastureid: this.table.move1.pastureid,
  1048. barid: this.table.move1.barid,
  1049. lppid: evt.id,
  1050. times: evt.times,
  1051. ftid: this.table.move1.ftid,
  1052. ptsid: this.table.move1.ptsid,
  1053. ptid: this.table.move1.ptid,
  1054. fttype: this.table.move1.fttype,
  1055. timesTem: this.table.move1.times
  1056. }}
  1057. this.requestParam.data[1] = { 'name': 'updateLpplandtlSorts', 'type': 'e', 'parammaps': {
  1058. pastureid: evt.pastureid,
  1059. sort: evt.sort,
  1060. lppid: evt.id
  1061. }}
  1062. this.requestParam.data[2] = { 'name': 'deleteLppd', 'type': 'e', 'parammaps': {
  1063. pastureid: evt.pastureid,
  1064. id: this.table.move1.id
  1065. }}
  1066. this.requestParam.data[3] = { 'name': 'insertLppd', 'type': 'e', 'parammaps': {
  1067. pastureid: evt.pastureid,
  1068. lppid: evt.id,
  1069. barid: this.table.move1.barid,
  1070. barname: this.table.move1.barname,
  1071. fpdid: this.table.move1.fpdid,
  1072. fttype: this.table.move1.fttype,
  1073. lweight: this.table.move1.weight,
  1074. sort: evt.sort,
  1075. tmrid: evt.tmrid,
  1076. tmrname: evt.tmrname,
  1077. background: this.table.move1.background,
  1078. ccountradio: this.table.move1.ccountradio,
  1079. cowcount: this.table.move1.cowcount
  1080. }}
  1081. console.log('撒料位下-下新增', this.requestParam)
  1082. ExecDataByConfig(this.requestParam).then(response => {
  1083. console.log('撒料位新增保存发送参数', this.requestParam)
  1084. if (response.msg === 'fail') {
  1085. this.$notify({ title: '保存失败', message: response.data, type: 'warning', duration: 2000 })
  1086. this.getTimesList()
  1087. this.getSmallMenuList()
  1088. this.getList()
  1089. } else {
  1090. this.$notify({ title: '', message: '保存成功', type: 'success', duration: 2000 })
  1091. this.getIsDisplay()
  1092. }
  1093. })
  1094. } else if (this.table.changeList.length == 1) {
  1095. if (this.table.isGoing == true) {
  1096. console.log(11111)
  1097. this.requestParam.common = { 'returnmap': '0' }
  1098. this.requestParam.data = []
  1099. this.requestParam.data[0] = { 'name': 'checkLLPDetailInsert', 'type': 'e', 'parammaps': {
  1100. pastureid: evt.pastureid,
  1101. sort: evt.sort,
  1102. lppid: evt.id
  1103. }}
  1104. this.requestParam.data[1] = { 'name': 'deleteLppd', 'type': 'e', 'parammaps': {
  1105. pastureid: evt.pastureid,
  1106. id: this.table.move1.id
  1107. }}
  1108. this.requestParam.data[2] = { 'name': 'insertLppd', 'type': 'e', 'parammaps': {
  1109. pastureid: evt.pastureid,
  1110. lppid: evt.id,
  1111. barid: this.table.move1.barid,
  1112. barname: this.table.move1.barname,
  1113. fpdid: this.table.move1.id,
  1114. fttype: this.table.move1.fttype,
  1115. lweight: this.table.move1.weight,
  1116. sort: evt.sort,
  1117. tmrid: evt.tmrid,
  1118. tmrname: evt.tmrname,
  1119. background: this.table.move1.background
  1120. }}
  1121. this.requestParam.data[3] = { 'name': 'updateFpdetailUse', 'type': 'e', 'parammaps': {
  1122. pastureid: this.table.move1.pastureid,
  1123. id: this.table.move1.id,
  1124. fttype: this.table.move1.fttype,
  1125. statue: 1
  1126. }}
  1127. console.log('撒料位新增', this.requestParam)
  1128. ExecDataByConfig(this.requestParam).then(response => {
  1129. console.log('撒料位新增保存发送参数', this.requestParam)
  1130. if (response.msg === 'fail') {
  1131. this.$notify({ title: '保存失败', message: response.data, type: 'warning', duration: 2000 })
  1132. this.getTimesList()
  1133. this.getList()
  1134. } else {
  1135. this.$notify({ title: '', message: '保存成功', type: 'success', duration: 2000 })
  1136. this.getIsDisplay()
  1137. }
  1138. })
  1139. this.table.isGoing = false
  1140. } else {
  1141. this.table.isGoing = true
  1142. }
  1143. }
  1144. }
  1145. },
  1146. // 编辑-撒料设备
  1147. changeEquipment(item, row, fttype, myid) {
  1148. var objList = {}
  1149. for (let i = 0; i < row.arrList.length; i++) {
  1150. row.arrList[i].tmrname = this.equipmentList.find(obj => obj.id === item).tname
  1151. if (row.arrList[i].fttype == fttype && row.arrList[i].id == myid) {
  1152. objList = row.arrList[i]
  1153. }
  1154. if (row.tmrid == row.arrList[i].tmrid) {
  1155. if (row.tmrid !== item) {
  1156. this.$message({ type: 'warning', message: '混料设备不可与其它撒料设备同时选择', duration: 2000 })
  1157. this.getList()
  1158. return false
  1159. }
  1160. } else {
  1161. if (row.tmrid == item) {
  1162. this.$message({ type: 'warning', message: '混料设备不可与其它撒料设备同时选择', duration: 2000 })
  1163. this.getList()
  1164. return false
  1165. }
  1166. }
  1167. }
  1168. console.log(row)
  1169. this.requestParam = {}
  1170. this.requestParam.common = { 'returnmap': '0' }
  1171. this.requestParam.data = []
  1172. this.requestParam.data[0] = { 'name': 'updateLppd', 'type': 'e', 'parammaps': {
  1173. pastureid: row.pastureid,
  1174. lppid: row.id,
  1175. barid: objList.barid,
  1176. barname: objList.barname,
  1177. fpdid: objList.fpdid,
  1178. fttype: objList.fttype,
  1179. lweight: objList.weight,
  1180. sort: objList.sort,
  1181. tmrid: objList.tmrid,
  1182. tmrname: objList.tmrname,
  1183. background: objList.background,
  1184. id: objList.id
  1185. }}
  1186. ExecDataByConfig(this.requestParam).then(response => {
  1187. console.log('编辑保存发送参数', this.requestParam)
  1188. if (response.msg === 'fail') {
  1189. this.$notify({ title: '保存失败', message: response.data, type: 'warning', duration: 2000 })
  1190. } else {
  1191. this.$notify({ title: '', message: '保存成功', type: 'success', duration: 2000 })
  1192. this.getList()
  1193. this.getTimesList()
  1194. }
  1195. })
  1196. },
  1197. dbclickWeight(row) {
  1198. console.log(row)
  1199. row.isWeight = true
  1200. row.focusState = true
  1201. this.dropState = true
  1202. },
  1203. // 编辑-重量
  1204. blurWeight(row, fttype, myid) {
  1205. var objList = {}
  1206. for (let i = 0; i < row.arrList.length; i++) {
  1207. if (row.arrList[i].fttype == fttype && row.arrList[i].id == myid) {
  1208. objList = row.arrList[i]
  1209. }
  1210. }
  1211. if (objList.weight !== '') {
  1212. if (parseFloat(objList.weight) <= 0) {
  1213. this.$message({ type: 'error', message: '重量不可输入小于0的数据', duration: 2000 })
  1214. return false
  1215. }
  1216. }
  1217. if (objList.weight == '') { objList.weight = 0 }
  1218. this.requestParam = {}
  1219. this.requestParam.common = { 'returnmap': '0' }
  1220. this.requestParam.data = []
  1221. this.requestParam.data[0] = { 'name': 'checkFPdLeftW', 'type': 'v', 'parammaps': {
  1222. pastureid: objList.pastureid,
  1223. fpdid: objList.fpdid,
  1224. fttype: objList.fttype,
  1225. lweight: String(parseFloat(objList.weight) - parseFloat(objList.lweight))
  1226. }}
  1227. this.requestParam.data[1] = { 'name': 'updateLppd', 'type': 'e', 'parammaps': {
  1228. pastureid: row.pastureid,
  1229. lppid: row.id,
  1230. barid: objList.barid,
  1231. barname: objList.barname,
  1232. fpdid: objList.fpdid,
  1233. fttype: objList.fttype,
  1234. lweight: objList.weight,
  1235. sort: objList.sort,
  1236. tmrid: objList.tmrid,
  1237. tmrname: objList.tmrname,
  1238. background: objList.background,
  1239. id: objList.id
  1240. }}
  1241. this.requestParam.data[2] = { 'name': 'updateFpdetailUse', 'type': 'e', 'parammaps': {
  1242. pastureid: objList.pastureid,
  1243. id: objList.fpdid,
  1244. fttype: objList.fttype,
  1245. lweight: String(parseFloat(objList.weight) - parseFloat(objList.lweight))
  1246. }}
  1247. ExecDataByConfig(this.requestParam).then(response => {
  1248. console.log('编辑保存发送参数', this.requestParam)
  1249. if (response.msg === 'fail') {
  1250. this.$notify({ title: '保存失败', message: response.data, type: 'warning', duration: 2000 })
  1251. this.getList()
  1252. this.getTimesList()
  1253. } else {
  1254. this.$notify({ title: '', message: '保存成功', type: 'success', duration: 2000 })
  1255. this.getList()
  1256. this.getTimesList()
  1257. this.isWeight = false
  1258. }
  1259. })
  1260. },
  1261. handleTakeEffectChange() {
  1262. console.log('点击了生效')
  1263. },
  1264. handleIssplitChange() {
  1265. console.log('是否提前小料拆分')
  1266. },
  1267. // 撒料位删除
  1268. handleFLDelete(ele, row) {
  1269. console.log(ele, row, '点击了撒料删除')
  1270. this.selectList = []
  1271. this.requestParam = {}
  1272. this.requestParam.common = { 'returnmap': '0' }
  1273. this.requestParam.data = []
  1274. this.requestParam.data[0] = { 'name': 'deleteLppd', 'type': 'e', 'parammaps': {
  1275. pastureid: ele.pastureid,
  1276. id: ele.id
  1277. }}
  1278. this.requestParam.data[1] = { 'name': 'updateFpdetailUse', 'type': 'e', 'parammaps': {
  1279. pastureid: ele.pastureid,
  1280. id: ele.fpdid,
  1281. fttype: ele.fttype,
  1282. lweight: '-' + parseFloat(ele.weight)
  1283. }}
  1284. ExecDataByConfig(this.requestParam).then(response => {
  1285. console.log('删除保存发送参数', this.requestParam)
  1286. if (response.msg === 'fail') {
  1287. this.$notify({ title: '删除失败', message: response.data, type: 'warning', duration: 2000 })
  1288. } else {
  1289. this.$notify({ title: '', message: '删除成功', type: 'success', duration: 2000 })
  1290. this.getList()
  1291. this.getTimesList()
  1292. }
  1293. })
  1294. },
  1295. handleSelect(val) {
  1296. console.log('勾选数据', val)
  1297. this.selectList = val
  1298. },
  1299. // 减少车次
  1300. handleReduceTrains() {
  1301. if (this.selectList.length == 0) {
  1302. this.$message({ type: 'error', message: '请选择车次', duration: 2000 })
  1303. return false
  1304. } else {
  1305. // 减少对应车次
  1306. for (let i = 0; i < this.selectList.length; i++) {
  1307. if (this.selectList[i].arrList.length > 0) {
  1308. this.$message({ type: 'error', message: '本车次已添加栏舍不可删除', duration: 2000 })
  1309. return false
  1310. }
  1311. }
  1312. MessageBox.confirm('是否确认删除此信息?', {
  1313. confirmButtonText: '确认', cancelButtonText: '取消', type: 'warning'
  1314. }).then(() => {
  1315. console.log(this.selectList)
  1316. this.requestParam = {}
  1317. this.requestParam.common = { 'returnmap': '0' }
  1318. this.requestParam.data = []
  1319. this.requestParam.data[0] = { 'name': 'insertSpotList', 'resultmaps': { 'list': this.selectList }}
  1320. this.requestParam.data[0].children = []
  1321. this.requestParam.data[0].children[0] = { 'name': 'deleteLpp', 'type': 'e', 'parammaps': {
  1322. id: '@insertSpotList.id',
  1323. pastureid: '@insertSpotList.pastureid'
  1324. }}
  1325. ExecDataByConfig(this.requestParam).then(response => {
  1326. console.log('删除保存发送参数', this.requestParam)
  1327. if (response.msg === 'fail') {
  1328. this.$notify({ title: '删除失败', message: response.data, type: 'warning', duration: 2000 })
  1329. } else {
  1330. this.$notify({ title: '', message: '删除成功', type: 'success', duration: 2000 })
  1331. this.getList()
  1332. }
  1333. })
  1334. })
  1335. }
  1336. },
  1337. // 行内删除
  1338. handleRowDelete(row) {
  1339. console.log(row, '点击了行删除')
  1340. if (row.arrList.length == 0) {
  1341. MessageBox.confirm('是否确认删除此信息?', {
  1342. confirmButtonText: '确认', cancelButtonText: '取消', type: 'warning'
  1343. }).then(() => {
  1344. this.selectList = []
  1345. this.requestParam = {}
  1346. this.requestParam.name = 'deleteLpp'
  1347. this.requestParam.parammaps = {}
  1348. this.requestParam.parammaps.pastureid = row.pastureid
  1349. this.requestParam.parammaps.id = row.id
  1350. PostDataByName(this.requestParam).then(response => {
  1351. if (response.msg === 'fail') {
  1352. this.$notify({ title: '删除失败', message: response.data, type: 'warning', duration: 2000 })
  1353. } else {
  1354. this.$notify({ title: '成功', message: '删除成功', type: 'success', duration: 2000 })
  1355. this.getList()
  1356. }
  1357. })
  1358. }).catch(() => {
  1359. this.$message({ type: 'info', message: '已取消删除' })
  1360. })
  1361. } else {
  1362. this.$message({ type: 'error', message: '本车次已添加栏舍不可删除', duration: 2000 })
  1363. return false
  1364. }
  1365. },
  1366. handleLeftButton() { // 向左
  1367. console.log('向左', this.isLeftButton)
  1368. this.isLeftButton = false
  1369. this.isRightButton = true
  1370. this.$refs.listR.style.width = '46%'
  1371. this.$refs.listR.style.zIndex = 4
  1372. // this.$refs.listRight.style.zIndex = 4
  1373. // this.$refs.listRight2.style.zIndex = 4
  1374. this.getSmallMenuList()
  1375. },
  1376. handleRightButton() { // 向右
  1377. console.log('向右', this.isLeftButton)
  1378. this.isLeftButton = true
  1379. this.isRightButton = false
  1380. this.$refs.list.style.zIndex = 1
  1381. this.$refs.listR.style.width = '50px'
  1382. this.$refs.listR.style.zIndex = 1
  1383. this.$nextTick(() => {
  1384. this.$refs.listRight.style.zIndex = 1
  1385. this.$refs.listRight2.style.zIndex = 1
  1386. })
  1387. }
  1388. }
  1389. }
  1390. </script>
  1391. <style lang="scss" scoped>
  1392. /deep/ .el-radio-button__orig-radio:checked+.el-radio-button__inner {
  1393. color: #fff;
  1394. background-color: #009C69;
  1395. border-color: #009C69;
  1396. -webkit-box-shadow: -1px 0 0 0 #009C69;
  1397. box-shadow: -1px 0 0 0 #009C69;
  1398. }
  1399. .not-select{
  1400. -moz-user-select:none; /*火狐*/
  1401. -webkit-user-select:none; /*webkit浏览器*/
  1402. -ms-user-select:none; /*IE10*/
  1403. -khtml-user-select:none; /*早期浏览器*/
  1404. user-select:none;
  1405. }
  1406. </style>
  1407. <style lang="scss">
  1408. /deep/ :focus {
  1409. outline: 0;
  1410. }
  1411. :focus-visible {
  1412. outline: 0 !important;
  1413. }
  1414. // 下拉框
  1415. .filter-item2 .el-input--suffix .el-input__inner{
  1416. height: 30px !important;
  1417. font-size: 8px;
  1418. padding: 0 2px;
  1419. }
  1420. .filter-item2 .el-input--suffix .el-input__suffix .el-input__suffix-inner .el-input__icon{
  1421. line-height: 30px !important;
  1422. }
  1423. // 输入框
  1424. .filter-item2 .el-input__inner{
  1425. height: 30px !important;
  1426. font-size: 8px;
  1427. padding: 0 2px;
  1428. }
  1429. </style>
  1430. <style lang="scss">
  1431. .menuList{
  1432. height: 190px;background: red;border-bottom: 2px solid #d8dce5; box-shadow: 0 1px 6px 0 rgba(0, 0, 0, 0.12), 0 0 6px 0 rgba(0, 0, 0, 0.04);
  1433. .menuList-t{
  1434. height: 60px;background: #fff;display: flex;justify:center;align-items:center;display:-webkit-flex; flex-direction: row; flex-wrap: wrap; justify-content: space-between;
  1435. .menuList-t-l{}
  1436. .menuList-t-r{
  1437. display: flex; flex-direction: row; flex-wrap: wrap; justify-content: space-between;position: relative;
  1438. .menuList-t-r-l{
  1439. margin-right:10px;cursor:pointer;width:150px;height: 20px;line-height:20px; text-align: center; background: rgba(25, 138, 244, 0); border: 1px solid #1BBD89; border-radius: 2px;font-size:12px;color: #1BBD89;
  1440. }
  1441. .menuList-t-r-r{
  1442. margin-right:10px;cursor:pointer;width:150px;height: 20px;line-height:20px; text-align: center; background: rgba(25, 138, 244, 0); border: 1px solid #1BBD89; border-radius: 2px;font-size:12px;color: #1BBD89;
  1443. }
  1444. .columnHouse{
  1445. width:650px;background: #fff; box-shadow: 0 0 6px 6px rgba(0, 0, 0, 0.04), 0 0 6px 6px rgba(0, 0, 0, 0.04);position: absolute;right: 0;top: 25px;z-index: 5;
  1446. .el-table {
  1447. height: 250px;
  1448. overflow: auto;
  1449. }
  1450. }
  1451. }
  1452. }
  1453. .menuList-b{
  1454. height: 130px;background: #fff;position: relative;
  1455. ::-webkit-scrollbar{ width: 7px; height: 7px; background-color: #F5F5F5; }
  1456. ::-webkit-scrollbar-track { box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.3); -webkit-box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.3); border-radius: 10px; background-color: #F5F5F5; }
  1457. ::-webkit-scrollbar-thumb{ border-radius: 10px; box-shadow: inset 0 0 6px rgba(0, 0, 0, .1); -webkit-box-shadow: inset 0 0 6px rgba(0, 0, 0, .1); background-color: #c8c8c8; }
  1458. .draggableList{position: absolute;width: 100%;margin: 0 0; height: 130px; list-style: none;padding:0 0;overflow: auto;font-size: 12px;
  1459. .draggableTitle{float: left;width: 105px;white-space: nowrap;overflow: hidden; text-overflow: ellipsis;margin:5px 5px;border-radius: 7px;text-align: center;color:#000;height: 36px;line-height: 36px;}
  1460. li{
  1461. text-align: center;color:#fff;
  1462. .draggableName{display:block;width: 100%;overflow: hidden; text-overflow:ellipsis; white-space: nowrap;}
  1463. }
  1464. }
  1465. }
  1466. }
  1467. .list-group2{
  1468. .list-group-item2{
  1469. width: 220px;height: 50px;overflow: hidden; float: left;margin: 5px 5px;position: relative;
  1470. .arr-t{height: 50px;border-radius:5px 5px;}
  1471. .arr-l{
  1472. float: left;width: 60px;height: 50px;overflow: hidden;background: red;border-radius:5px 50% 50% 5px;
  1473. .arr-l-t{
  1474. position: relative;
  1475. .arr-l-t-t{
  1476. width: 0;height: 0; border-top: 26px solid #3479f2; border-right: 26px solid transparent;
  1477. }
  1478. .arr-l-t-b{
  1479. position: absolute;top: 4px;left: 1px;color: #fff;width: 10px; height: 10px;
  1480. .el-input--suffix{
  1481. opacity:0;
  1482. .el-input__inner{height: 10px;}
  1483. }
  1484. }
  1485. }
  1486. .arr-l-b{
  1487. width: 45px;position: absolute;top: 15px;left: 10px;color: #333;font-size: 12px;
  1488. .tmrname{width: 100%;overflow: hidden; text-overflow:ellipsis; white-space: nowrap;}
  1489. }
  1490. }
  1491. .arr-c{position: absolute;top: 0px;left: 0;}
  1492. .arr-r{
  1493. float: right;width: 160px;height: 50px;overflow: hidden;line-height: 50px;
  1494. .arr-r-l{
  1495. float: left;width: 85px;
  1496. .barname{width: 100%;overflow: hidden; text-overflow:ellipsis; white-space: nowrap;}
  1497. }
  1498. .arr-r-c{float: left;width: 10px;}
  1499. .arr-r-r{
  1500. float: left;width: 65px;
  1501. .weight{width: 100%;overflow: hidden; text-overflow:ellipsis; white-space: nowrap;}
  1502. }
  1503. }
  1504. }
  1505. }
  1506. </style>
  1507. <style>
  1508. .draggableWeight{display:block;line-height: 18px;height: 18px; color: #000; width: 100%; margin: 0 auto;}
  1509. </style>