在线观看不卡亚洲电影_亚洲妓女99综合网_91青青青亚洲娱乐在线观看_日韩无码高清综合久久

鍍金池/ 問(wèn)答/ HTML5問(wèn)答

angular,if($scope.phone && $scope.password && $scope.code){點(diǎn)亮下一步}

祈歡 回答

clipboard.png
運(yùn)行了下你的代碼 沒(méi)什么問(wèn)題 應(yīng)該是其他地方對(duì)數(shù)據(jù)進(jìn)行了操作導(dǎo)致的?

默念 回答

a頁(yè)面加個(gè)定時(shí)輪詢,從服務(wù)器端獲取用戶的登錄狀態(tài),如果有改變就刷新

深記你 回答

用flex可以 上部flex-shrink設(shè)置0,下部flex-grow設(shè)置1,flex-direction設(shè)置為column;

賤人曾 回答

問(wèn)題已解決,是瀏覽器緩存問(wèn)題。只需要禁止瀏覽器使用緩存就可以。

舊酒館 回答

請(qǐng)貼出相關(guān)代碼

this.$refs.refsName在類型定義上,并沒(méi)有g(shù)etBoundingClientRect的方法定義,所以你調(diào)用的時(shí)候會(huì)報(bào)類型錯(cuò)誤。
再比如我們項(xiàng)目中有人這樣定義:

let ctrlLayout: Object= undefined;
ctrlLayout = {
   options: {}
}

然后我們動(dòng)態(tài)去options中添加屬性的時(shí)候:

ctrlLayout.options.id = "field1";

就會(huì)報(bào)同樣的錯(cuò)誤了,因?yàn)镺bject并沒(méi)有關(guān)于options.id的定義。
所以這個(gè)時(shí)候改成let ctrlLayout: any= undefined;就可以了。

撿肥皂 回答

注意stop不能省略

<!DOCTYPE html>
<html>
    <head>
        <meta charset="UTF-8">
        <title></title>
        <style type="text/css">
            #box{
                margin: 100px;
            }
        </style>
    </head>
    <body>
        <div id="box">
              <Poptip  title="提示標(biāo)題" content="提示內(nèi)容" v-model="visible">    
                  <div slot="title"><i>自定義標(biāo)題</i></div>
                    <div slot="content">
                       111
                    </div>
                </Poptip>
           <button @click.stop="show()" >激活</button>
        </div>
        <script src="https://cdn.jsdelivr.net/npm/vue"></script>
        <!-- 引入Vue -->
<link rel="stylesheet" >
<!-- import iView -->
<script src="http://unpkg.com/iview/dist/iview.min.js"></script>
<script>
    var vm = new Vue({
        el:"#box",
        data:{
            visible:false
        },
        methods:{
            show:function(e){
            this.visible = true;    
            }
        },
        mounted:function(){
            
        }
    })
</script>
    </body>
</html>
有你在 回答

clipboard.png

只是為了避免全局污染,該怎么取名還是怎么取。

css-module

孤影 回答
// 每一個(gè)實(shí)例都只能open一條socket線路,用鎖機(jī)制防止重復(fù)open
// 本例中不使用心跳檢測(cè),為了方便,只要close是非主動(dòng)觸發(fā)且前端能捕捉到的(如瀏覽器主動(dòng)斷開(kāi),服務(wù)器主動(dòng)斷開(kāi)),都會(huì)進(jìn)行自動(dòng)重連
export default class MyWebSocket {
  constructor(url) {
    this.url = url;

    // close來(lái)源判斷及后續(xù)操作
    this.closeConfig = {
      resolve: null,
      closing: false
    }
    // promise池
    this.promisePool = {};
  }

  tokenCheck(req, rsp) {
    // 此處根據(jù)自己的數(shù)據(jù)結(jié)構(gòu)進(jìn)行tokenCheck的判斷,返回一個(gè)boolean
  }

  open() {
    return new Promise((resolve, reject) => {
      if (typeof this._websocket === 'undefined') {
        this._websocket = new WebSocket(this.url);
        this._websocke.open = (e) => {
          resolve({e, ws: this});
        };
        this._websocket.onerror = (e) => {
          reject(e);
        }
      }
      this._websocket.onclose = (e) => {
        // 非主動(dòng)close
        if (!this.closeConfig.closing) {
          console.log('reconnect');
          // 對(duì)應(yīng)的重連操作
        }
        // 若手動(dòng)close,恢復(fù)初始狀態(tài)
        this.closeConfig.closing = false;
      }

      this._websocket.onmessage = (e) => {
        const key = e.content.token;
        const req = this.promisePool[key]
        req.resolve(e);
        delete this.promisePool[key];
      };
    });
  }

  close() {
    this.closeConfig.closing = true;
    this._websocket.close();
  }
  // token包含在content中
  send(name, content) {
    return new Promise((resolve, reject) => {
      this.promisePool[content.token] = {
        content,
        resolve,
        reject,
        name
      };
      this._websocket.send({name, content});
    });
  }
北城荒 回答

1.你的Nginx怎么配置的
2.你自己的路由怎么寫(xiě)的
3.開(kāi)發(fā)環(huán)境有沒(méi)有問(wèn)題

喜歡你 回答

能不能發(fā)送完,要看數(shù)據(jù)量和網(wǎng)速,而不是條數(shù)!

耍太極 回答

可以使用 @oraoto 的思路, 寫(xiě)個(gè)lua腳本.
如果lua腳本無(wú)法實(shí)現(xiàn)業(yè)務(wù)邏輯, 可以使用WATCH命令, 或者自己實(shí)現(xiàn)一個(gè)簡(jiǎn)單的鎖, 鎖住這個(gè)鍵.
可以參考Redis實(shí)戰(zhàn)中《4.4 Redis事務(wù)》 和 《6.2分布式鎖》

忠妾 回答

我看了下API, angular material的datepicker沒(méi)有提供設(shè)置format的option。
但也能做,date input沒(méi)有跟format綁定上,所以你手動(dòng)set值為31/12/1997也是可以的。

MatDatepicker有個(gè)output事件closedStream,你可以利用一下,就是在date picker關(guān)閉的時(shí)候,拿到date轉(zhuǎn)換成你需要的格式,然后重新將值放到input上。

離魂曲 回答

1.強(qiáng)制刷新頁(yè)面 2.查看 apache 配置文件中是否進(jìn)行過(guò) RewriteRule url重寫(xiě)。