🦀️ fix: 修复组合商品管理模块bug

This commit is contained in:
wangsongsole 2024-02-27 10:07:15 +08:00
parent 8789083edb
commit ac2fad21c6
1 changed files with 4 additions and 3 deletions

View File

@ -279,7 +279,7 @@ export default class combiningAdd extends React.Component {
/* 编辑 */
if (this.state.isState === 2) {
data.disabled = true
data.disabled = this.codeStatus !== -1 ? true : false
data.stock = item.stock
data.quantity = item.total_stock
const exclude = ["total_stock", "use_stock"]
@ -994,7 +994,7 @@ export default class combiningAdd extends React.Component {
<div className="line">{this.state.codeInfo.restrict}</div>
</FormItem>
{this.state.isState === 2 ? (
{this.state.isState === 2 && this.codeStatus !== -1 ? (
<>
<FormItem labelname="发放总量" prop="issued" id="issued">
<div className="line">{this.state.codeInfo.issued}</div>
@ -1181,12 +1181,13 @@ export default class combiningAdd extends React.Component {
multiple
value={this.state.rank}
placeholder="选择一项"
disabled={this.state.isState == 2 && this.codeStatus !== -1}
width={410}
onChange={(e) => {
this.onRankChange(e)
}}
/>
{this.state.isState !== 2 ? (
{this.state.isState !== 2 || this.codeStatus === -1 ? (
<Button
type="primary"
style={{ marginLeft: "20px" }}