buli
2023-07-11 cd05a7b0ab8dd5838f8998fb36fc0435fd9c5b84
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
<template>
  <template if:true={showSpinner}>
    <!-- <lightning-spinner size="medium" variant="brand"></lightning-spinner> -->
    <div class="slds-spinner_container">
      <div
        role="status"
        class="slds-spinner slds-spinner_medium slds-spinner_brand"
      >
        <span class="slds-assistive-text">Loading</span>
        <div class="slds-spinner__dot-a"></div>
        <div class="slds-spinner__dot-b"></div>
      </div>
    </div>
  </template>
  <c-common-toast></c-common-toast>
  <div style="border: 1px solid #d4d4d4; border-radius: 5px">
    <div
      style="
        border-top: 3px solid #51606e;
        border-bottom: 1px solid #d4d4d4;
        padding: 3px;
      "
    >
      <!-- <p style="font-size: 18px;"><strong>库存管理</strong></p> -->
      <lightning-layout>
        <lightning-layout-item padding="around-small">
          <p style="font-size: 18px">
            <strong>库存管理</strong>
          </p>
        </lightning-layout-item>
      </lightning-layout>
    </div>
    <div style="padding: 10px">
      <div
        style="
          border: 1px solid #d4d4d4;
          border-radius: 5px;
          margin-bottom: 7px;
        "
      >
        <div
          style="
            border-top: 3px solid #51606e;
            border-bottom: 1px solid #d4d4d4;
            padding: 10px;
          "
        >
          <!-- <lightning-button variant="brand" class = 'lexstyle' style="margin:12px;" label="库存盘点" title="库存盘点"
                        onclick={inventoryCount}></lightning-button>
                    <lightning-button variant="brand" class = 'lexstyle' style="margin: 12px;" label="过期库存销存" title="过期库存销存"
                        onclick={handleExpired}></lightning-button>
                    <lightning-button variant="brand" class = 'lexstyle' style="margin: 12px;" label="拆盒" title="拆盒" onclick={removeBox}></lightning-button>
                    <lightning-button variant="brand" class = 'lexstyle' style="margin: 12px;" label="取消拆盒" title="取消拆盒"
                        onclick={cancelremoveBox}></lightning-button> -->
          <button
            style="margin-left: 5px"
            class="slds-button slds-button_neutral slds-button_stretch lexBorder"
            label="库存盘点"
            onclick={inventoryCount}
          >
            库存盘点
          </button>
          <button
            class="slds-button slds-button_neutral slds-button_stretch lexButtoun"
            label="过期库存销存"
            style="margin-left: 60px"
            onclick={handleExpired}
          >
            过期库存销存
          </button>
          <button
            class="slds-button slds-button_neutral slds-button_stretch lexButtoun"
            label="拆盒"
            style="margin-left: 60px"
            onclick={removeBox}
          >
            拆盒
          </button>
          <button
            class="slds-button slds-button_neutral slds-button_stretch lexButtoun"
            label="取消拆盒"
            style="margin-left: 60px"
            onclick={cancelremoveBox}
          >
            取消拆盒
          </button>
        </div>
      </div>
 
      <div
        style="
          border: 1px solid #d4d4d4;
          border-radius: 5px;
          margin-bottom: 7px;
          margin-top: 30px;
        "
      >
        <div
          style="
            border-top: 3px solid #51606e;
            border-bottom: 1px solid #d4d4d4;
            padding: 3px;
            height: 115px;
          "
        >
          <table style="margin-top: 10px">
            <colgroup>
              <col width="160px" />
              <col width="100px" />
              <col width="10px" />
              <col width="70px" />
              <col width="100px" />
              <col width="10px" />
              <col width="70px" />
              <col width="100px" />
              <col width="10px" />
              <col width="90px" />
              <col width="100px" />
              <col width="85px" />
              <col width="100px" />
              <col width="10px" />
              <col width="70px" />
              <col width="100px" />
            </colgroup>
            <tbody>
              <tr>
                <td style="width: 10px"></td>
                <td style="width: 250px">
                  <div
                    style="width: 90px; margin-left: 12px"
                    class="searchName"
                  >
                    消耗品名称
                  </div>
                </td>
                <td style="width: 21%">
                  <lightning-input
                    class="searchName"
                    type="text"
                    name="Name"
                    label="消耗品名称"
                    value={Name}
                    variant="label-hidden"
                    onchange={dataChange}
                    data-field="Name"
                  ></lightning-input>
                </td>
                <td style="width: 150px">
                  <div
                    style="width: 90px; text-align: center"
                    class="searchName"
                  >
                    第3分类
                  </div>
                </td>
                <td style="width: 21%">
                  <lightning-combobox
                    class="inputFont"
                    style="margin-left: 5px"
                    name="CategoryThree"
                    label="第3分类"
                    value={value}
                    placeholder="请选择..."
                    options={category3Options}
                    variant="label-hidden"
                    data-field="CategoryThree"
                    onchange={dataChange}
                  ></lightning-combobox>
                </td>
                <td style="width: 150px">
                  <div
                    style="width: 90px; text-align: center"
                    class="searchName"
                  >
                    第4分类
                  </div>
                </td>
                <td style="width: 21%">
                  <lightning-combobox
                    class="inputFont"
                    name="CategoryFour"
                    label="第4分类"
                    value={value}
                    placeholder="请选择..."
                    options={category4Options}
                    variant="label-hidden"
                    data-field="CategoryFour"
                    onchange={dataChange}
                  ></lightning-combobox>
                </td>
                <td style="width: 150px">
                  <div
                    style="width: 90px; text-align: center"
                    class="searchName"
                  >
                    第5分类
                  </div>
                </td>
                <td style="width: 21%">
                  <lightning-combobox
                    class="inputFont"
                    name="CategoryFive"
                    label="第5分类"
                    value={value}
                    placeholder="请选择..."
                    options={category5Options}
                    variant="label-hidden"
                    data-field="CategoryFive"
                    onchange={dataChange}
                  ></lightning-combobox>
                </td>
                <td style="width: 1%"></td>
              </tr>
            </tbody>
          </table>
          <br />
          <div style="float: right; margin-right: 10px">
            <button
              class="slds-button slds-button_neutral slds-button_stretch lexsearchStyle"
              label="消耗品搜索"
              onclick={searchOrderDetail}
            >
              消耗品搜索
            </button>
            <button
              style="margin-left: 10px"
              class="slds-button slds-button_neutral slds-button_stretch lexclearStyle"
              label="清空"
              onclick={clearAll}
            >
              清空
            </button>
          </div>
        </div>
      </div>
      <div
        style="
          border: 1px solid #d4d4d4;
          border-radius: 5px;
          margin-bottom: 7px;
        "
      >
        <div
          style="
            border-top: 3px solid #51606e;
            border-bottom: 1px solid #d4d4d4;
            padding: 3px;
          "
        >
          <!-- <p style="font-size: 16px;"><strong>库存详情</strong></p> -->
          <lightning-layout>
            <lightning-layout-item padding="around-small">
              <p style="font-size: 18px">
                <strong>库存详情</strong>
              </p>
            </lightning-layout-item>
          </lightning-layout>
        </div>
        <div style="padding: 10px">
          <template if:true={showTable}>
            <c-lex-custom-lightning-datatable
              key-field="id"
              data={data}
              columns={columns}
              default-sort-direction={defaultSortDirection}
              sorted-direction={sortDirection}
              sorted-by={sortedBy}
              onsort={onHandleSort}
              hide-checkbox-column={hidecheckboxcolumn}
              style="word-wrap: break-word; word-break: break-all"
              class="wrapped-header-datatable"
            >
            </c-lex-custom-lightning-datatable>
          </template>
          <c-paginator
            onprevious={handlePrevious}
            onnext={handleNext}
            onpageschange={handlePageschange}
            onfirst={handleFirst}
            onlast={handleLast}
            page-size-options={pageSizeOptions}
            previous-button-disabled={previousButtonDisabled}
            next-button-disabled={nextButtonDisabled}
            record-start={recordStart}
            record-end={recordEnd}
            total-records={totalRecords}
          ></c-paginator>
        </div>
      </div>
    </div>
  </div>
</template>