<!DOCTYPE html>
<html lang="en">
<head>
   <meta charset="UTF-8">
   <meta http-equiv="X-UA-Compatible" content="IE=edge">
   <meta name="viewport" content="width=device-width, initial-scale=1.0">
   <title>要约收购</title>
   <link rel="stylesheet" href="../../lib/element-ui/css/index.css">
   <link rel="stylesheet" href="../../lib/common-style/css/reset.css">
   <link rel="stylesheet" href="./css/index.css">
   <style type="text/css">
      [v-cloak] {
         display: none;
      }
   </style>
</head>
<body oncontextmenu="return false" onselectstart="return false" ondragstart="return false" onbeforecopy="return false" oncopy=document.selection.empty()>
   <div id="yysgApp" v-cloak :class="configSkin == 'default' ? 'default' : 'white'">
      <div class="box" :style="contentStyleObj">
         <div class="box-con">
            <div class="title">
               <span>要约收购</span>
            </div>
            <div class="box-con-left">
               <p class="input-box stkcode-p">
                  <span class="field">要约代码:</span>
                  <el-input ref="stkinput" v-model="stkcode" maxlength="6" @input="stkcodeChange"></el-input>
               </p>
               <span class="stkname">{{stkname}}</span>
               <span class="submkttype-name">{{stktype_name}}</span>
               <p class="input-box">
                  <span class="field">股东代码:</span>
                  <el-select v-model="secuidValue" placeholder="" :popper-append-to-body="false">
                     <el-option v-for="item in secuidList" :key="item.marketname" :label="item.marketvalue" :value="item.marketname">
                     </el-option>
                  </el-select>
               </p>
               <div class="input-box">
                  <div class="input-box-son">
                     <span class="field">要约/解除:</span>
                     <el-select v-model="type" placeholder="请选择" :popper-append-to-body="false" @change="typeChange">
                        <el-option v-for="item in typeList" :key="item.keyvalue" :label="item.keyname" :value="item.keyvalue">
                        </el-option>
                     </el-select>
                  </div>
                  <div class="input-box-son" v-show="rightSgcodeShow">
                     <span class="field">收购编码:</span>
                     <el-select v-model="tenderer_id" placeholder="请选择" :popper-append-to-body="false" @change="sgcodeChange">
                        <el-option v-for="item in tendererArr" :key="item.tenderer_id" :label="item.tenderer_id" :value="item.tenderer_id">
                        </el-option>
                     </el-select>
                  </div>
               </div>
               <div class="input-box" v-show="sgcodeShow">
                  <span class="field">收购编码:</span>
                  <el-input v-model="sgcode" oninput="value=value.replace(/[^\d]/g, '')"></el-input>
               </div>
               <div class="input-box" v-show="!initShow">
                  <span class="field">要约价格:</span>
                  <el-input v-model="yyprice" @change="((val)=>{valueChange(val, 'yyprice')})" oninput="value=value.replace(/[^0-9.]/g,'')"></el-input>
               </div>
               <div class="input-box" v-show="sgpriceShow">
                  <div class="input-box-son">
                     <span class="field">收购价格:</span>
                     <el-input v-model="sgprice" @change="((val)=>{valueChange(val, 'sgprice')})" oninput="value=value.replace(/[^0-9.]/g,'')"></el-input>
                  </div>
                  <div class="input-box-con" v-show="rightSgcodeShow">
                     <span class="field">收购人名称:</span>
                     <span class="field" style="text-align: left;">{{tenderer_obj.tenderer_name}}</span>
                  </div>
               </div>
               <div class="input-box">
                  <div class="input-box-son">
                     <span class="field">委托数量:</span>
                     <el-input ref="numinput" oninput="value=value.replace(/[^\d]/g, '')" type="text" v-model="orderqty"></el-input>
                  </div>
                  <div class="input-box-con" v-show="rightSgcodeShow">
                     <span class="field">收购起止日:</span>
                     <span class="field" style="text-align: left;">{{tenderer_obj.date}}</span>
                  </div>
               </div>
               <div class="input-box operate">
                  <span class="field rewrite">重填</span>
                  <el-button class="order-btn" @click="order">委托</el-button>
               </div>
            </div>
         </div>
      </div>
      <div v-if="tipDialog">
         <div class="mask-box"></div>
         <div class="tip-dialog" :class="textLine == 'one' ? 'one-line' : 'more-line'">
            <div class="dialog-title tip-title">
               <span>富易</span>
               <span class="close-btn" @click="tipDialog=false"><i class="el-icon-close"></i></span>
            </div>
            <div class="tip-body">
               <div class="info-tip">
                  <span>
                     <img src="../../lib/common-style/images/infoico.png" alt="" v-if="successOrfail">
                     <img src="../../lib/common-style/images/successico.png" alt="" v-else>
                  </span>
                  <span v-html="info">{{info}}</span>
               </div>
            </div>
            <div class="dialog-footer tip-footer">
               <el-button class="sure" type="primary" @click="tipDialog=false">确定</el-button>
            </div>
         </div>
      </div>
      <div v-if="sgsubmit">
         <div class="mask-box"></div>
         <div class="submit-dialog" :class="{'low-dialog' : lowDialog}">
            <div class="dialog-title">
               <span>委托确认</span>
               <span class="close-btn" @click="sgsubmit=false"><i class="el-icon-close"></i></span>
            </div>
            <div class="submit-body">
               <h3 class="submit-body-title">【{{typeTitle}}】</h3>
               <div class="submit-data">
                  <p class="submit-p">
                     <span>股东账号:</span>
                     <span>{{origsecuidList[origsecuidList.findIndex(item => item.marketname == secuidValue)].marketvalue}}</span>
                  </p>
                  <p class="submit-p">
                     <span>证券代码:</span>
                     <span>{{stkcode}} {{stkname}}</span>
                  </p>
                  <p class="submit-p" v-show="rightSgcodeShow || sgcodeShow">
                     <span>收购编码:</span>
                     <span v-if="rightSgcodeShow">{{tenderer_id}}</span>
                     <span v-else>{{sgcode}}</span>
                  </p>
                  <p class="submit-p" v-show="rightSgcodeShow">
                     <span>收购人名称:</span>
                     <span>{{tenderer_obj.tenderer_name}}</span>
                  </p>
                  <p class="submit-p" v-show="!initShow">
                     <span>要约价格:</span>
                     <span>{{yyprice}}元</span>
                  </p>
                  <p class="submit-p" v-show="rightSgcodeShow">
                     <span>收购价格:</span>
                     <span>{{sgprice}}元</span>
                  </p>
                  <p class="submit-p">
                     <span>委托数量:</span>
                     <span>{{orderqty}}股</span>
                  </p>
               </div>
            </div>
            <div class="dialog-footer submit-footer">
               <el-button class="sure" type="primary" @click="entrustsure">确定</el-button>
               <el-button class="cancel" @click="sgsubmit=false">取消</el-button>
            </div>
         </div>
      </div>
   </div>
   <script src="../../lib/vue/vue.min.js"></script>
   <script src="../../lib/vue/axios.min.js"></script>
   <script src="../../lib/element-ui/js/index.js"></script>
   <script src="../../_common/service_fcfg.js"></script>
   <script src="../../_common/fy_client.js"></script>
   <script src="../../_common/service.js"></script>
   <script src="../../_common/fql.js"></script>
   <script src="../../_common/lts_result.js"></script>
   <script src="./js/index.js"></script>
</body>
</html>